This repository has been archived on 2024-07-27. You can view files and clone it, but cannot push or open issues or pull requests.
keksAccountGUI/node_modulesOLD/@webassemblyjs/ast
2019-08-11 20:48:02 +02:00
..
esm Update Framework 2019-08-11 20:48:02 +02:00
lib Update Framework 2019-08-11 20:48:02 +02:00
scripts Update Framework 2019-08-11 20:48:02 +02:00
LICENSE Update Framework 2019-08-11 20:48:02 +02:00
package.json Update Framework 2019-08-11 20:48:02 +02:00
README.md Update Framework 2019-08-11 20:48:02 +02:00
webassemblyjs-ast-1.7.10.tgz Update Framework 2019-08-11 20:48:02 +02:00

@webassemblyjs/ast

AST utils for webassemblyjs

Installation

yarn add @webassemblyjs/ast

Usage

Traverse

import { traverse } from "@webassemblyjs/ast";

traverse(ast, {
  Module(path) {
    console.log(path.node);
  }
});

Instruction signatures

import { signatures } from "@webassemblyjs/ast";

console.log(signatures);

Path methods

  • findParent: NodeLocator
  • replaceWith: Node => void
  • remove: () => void
  • insertBefore: Node => void
  • insertAfter: Node => void
  • stop: () => void

AST utils

  • function module(id, fields, metadata)
  • function moduleMetadata(sections, functionNames, localNames)
  • function moduleNameMetadata(value)
  • function functionNameMetadata(value, index)
  • function localNameMetadata(value, localIndex, functionIndex)
  • function binaryModule(id, blob)
  • function quoteModule(id, string)
  • function sectionMetadata(section, startOffset, size, vectorOfSize)
  • function loopInstruction(label, resulttype, instr)
  • function instruction(id, args, namedArgs)
  • function objectInstruction(id, object, args, namedArgs)
  • function ifInstruction(testLabel, test, result, consequent, alternate)
  • function stringLiteral(value)
  • function numberLiteralFromRaw(value, raw)
  • function longNumberLiteral(value, raw)
  • function floatLiteral(value, nan, inf, raw)
  • function elem(table, offset, funcs)
  • function indexInFuncSection(index)
  • function valtypeLiteral(name)
  • function typeInstruction(id, functype)
  • function start(index)
  • function globalType(valtype, mutability)
  • function leadingComment(value)
  • function blockComment(value)
  • function data(memoryIndex, offset, init)
  • function global(globalType, init, name)
  • function table(elementType, limits, name, elements)
  • function memory(limits, id)
  • function funcImportDescr(id, signature)
  • function moduleImport(module, name, descr)
  • function moduleExportDescr(exportType, id)
  • function moduleExport(name, descr)
  • function limit(min, max)
  • function signature(params, results)
  • function program(body)
  • function identifier(value, raw)
  • function blockInstruction(label, instr, result)
  • function callInstruction(index, instrArgs)
  • function callIndirectInstruction(signature, intrs)
  • function byteArray(values)
  • function func(name, signature, body, isExternal, metadata)
  • ConstantisModule
  • ConstantisModuleMetadata
  • ConstantisModuleNameMetadata
  • ConstantisFunctionNameMetadata
  • ConstantisLocalNameMetadata
  • ConstantisBinaryModule
  • ConstantisQuoteModule
  • ConstantisSectionMetadata
  • ConstantisLoopInstruction
  • ConstantisInstruction
  • ConstantisObjectInstruction
  • ConstantisIfInstruction
  • ConstantisStringLiteral
  • ConstantisNumberLiteral
  • ConstantisLongNumberLiteral
  • ConstantisFloatLiteral
  • ConstantisElem
  • ConstantisIndexInFuncSection
  • ConstantisValtypeLiteral
  • ConstantisTypeInstruction
  • ConstantisStart
  • ConstantisGlobalType
  • ConstantisLeadingComment
  • ConstantisBlockComment
  • ConstantisData
  • ConstantisGlobal
  • ConstantisTable
  • ConstantisMemory
  • ConstantisFuncImportDescr
  • ConstantisModuleImport
  • ConstantisModuleExportDescr
  • ConstantisModuleExport
  • ConstantisLimit
  • ConstantisSignature
  • ConstantisProgram
  • ConstantisIdentifier
  • ConstantisBlockInstruction
  • ConstantisCallInstruction
  • ConstantisCallIndirectInstruction
  • ConstantisByteArray
  • ConstantisFunc
  • ConstantassertModule
  • ConstantassertModuleMetadata
  • ConstantassertModuleNameMetadata
  • ConstantassertFunctionNameMetadata
  • ConstantassertLocalNameMetadata
  • ConstantassertBinaryModule
  • ConstantassertQuoteModule
  • ConstantassertSectionMetadata
  • ConstantassertLoopInstruction
  • ConstantassertInstruction
  • ConstantassertObjectInstruction
  • ConstantassertIfInstruction
  • ConstantassertStringLiteral
  • ConstantassertNumberLiteral
  • ConstantassertLongNumberLiteral
  • ConstantassertFloatLiteral
  • ConstantassertElem
  • ConstantassertIndexInFuncSection
  • ConstantassertValtypeLiteral
  • ConstantassertTypeInstruction
  • ConstantassertStart
  • ConstantassertGlobalType
  • ConstantassertLeadingComment
  • ConstantassertBlockComment
  • ConstantassertData
  • ConstantassertGlobal
  • ConstantassertTable
  • ConstantassertMemory
  • ConstantassertFuncImportDescr
  • ConstantassertModuleImport
  • ConstantassertModuleExportDescr
  • ConstantassertModuleExport
  • ConstantassertLimit
  • ConstantassertSignature
  • ConstantassertProgram
  • ConstantassertIdentifier
  • ConstantassertBlockInstruction
  • ConstantassertCallInstruction
  • ConstantassertCallIndirectInstruction
  • ConstantassertByteArray
  • ConstantassertFunc