Safe Haskell | None |
---|---|
Language | Haskell2010 |
Language.Wasm.Parser
Documentation
parseModuleFields :: [Lexeme] -> Either String [ModuleField] Source #
desugarize :: [ModuleField] -> Either String Module Source #
data ModuleField Source #
Constructors
MFType TypeDef | |
MFImport Import | |
MFFunc Function | |
MFTable Table | |
MFMem Memory | |
MFGlobal Global | |
MFExport Export | |
MFStart StartFunction | |
MFElem ElemSegment | |
MFData DataSegment |
Instances
data DataSegment Source #
Constructors
DataSegment | |
Fields
|
Instances
data ElemSegment Source #
Constructors
ElemSegment | |
Fields
|
Instances
Constructors
Export | |
Fields
|
data ExportDesc Source #
Constructors
ExportFunc FuncIndex | |
ExportTable TableIndex | |
ExportMemory MemoryIndex | |
ExportGlobal GlobalIndex |
Instances
Constructors
Global | |
Fields
|
Constructors
Function | |
Constructors
Import | |
Fields
|
data ImportDesc Source #
Constructors
ImportFunc (Maybe Ident) TypeUse | |
ImportTable (Maybe Ident) TableType | |
ImportMemory (Maybe Ident) Limit | |
ImportGlobal (Maybe Ident) GlobalType |
Instances
data Instruction Source #
Constructors
PlainInstr PlainInstr | |
BlockInstr | |
Fields
| |
LoopInstr | |
Fields
| |
IfInstr | |
Fields
|
Instances
Constructors
IndexedTypeUse TypeIndex (Maybe FuncType) | |
AnonimousTypeUse FuncType |
data PlainInstr Source #
Constructors
Instances
Constructors
RawModDef (Maybe Ident) Module | |
TextModDef (Maybe Ident) Text | |
BinaryModDef (Maybe Ident) ByteString |
Constructors
AssertReturn Action [Expression] | |
AssertReturnCanonicalNaN Action | |
AssertReturnArithmeticNaN Action | |
AssertTrap (Either Action ModuleDef) FailureString | |
AssertMalformed ModuleDef FailureString | |
AssertInvalid ModuleDef FailureString | |
AssertUnlinkable ModuleDef FailureString | |
AssertExhaustion Action FailureString |