package
0.42.12
Repository: https://github.com/onflow/cadence.git
Documentation: pkg.go.dev

# Packages

No description provided by the author

# Functions

AsValueType returns the value type for the given byte, or 0 if the byte is not a valid value type.
No description provided by the author
No description provided by the author
No description provided by the author

# Constants

MemoryPageSize is the size of a memory page: 64KiB.
ValueTypeExternRef is the `funcref` type, the type of first-class references to objects owned by the embedder.
ValueTypeFuncRef is the `funcref` type, the type of first-class references to functions.
ValueTypeI32 is the `i32` type, the type of 32 bit integers.
ValueTypeI64 is the `i64` type, the type of 64 bit integers.

# Structs

No description provided by the author
Buffer is a byte buffer, which allows reading and writing.
Code represents the code of a function.
CodeSectionLocalsCountMismatchError is returned when the sum of the compressed locals locals count in the code section does not match the number of locals in the code section of the WASM binary.
Data represents a data segment, which initializes a range of memory, at a given offset, with a static vector of bytes.
Exports represents an export.
Function represents a function.
FunctionCountMismatchError is returned when the WASM binary specifies information for a different number of functions than previously specified.
FunctionExport represents the export of a function.
FunctionType is the type of a function.
Import represents an import.
IncompleteNameError is returned the WASM binary specifies an incomplete name.
InstructionBlock is the 'block' instruction.
InstructionBr is the 'br' instruction.
InstructionBrIf is the 'br_if' instruction.
InstructionBrTable is the 'br_table' instruction.
InstructionCall is the 'call' instruction.
InstructionCallIndirect is the 'call_indirect' instruction.
InstructionDrop is the 'drop' instruction.
InstructionEnd is the 'end' instruction.
InstructionGlobalGet is the 'global.get' instruction.
InstructionGlobalSet is the 'global.set' instruction.
InstructionI32Add is the 'i32.add' instruction.
InstructionI32And is the 'i32.and' instruction.
InstructionI32Clz is the 'i32.clz' instruction.
InstructionI32Const is the 'i32.const' instruction.
InstructionI32Ctz is the 'i32.ctz' instruction.
InstructionI32DivS is the 'i32.div_s' instruction.
InstructionI32DivU is the 'i32.div_u' instruction.
InstructionI32Eq is the 'i32.eq' instruction.
InstructionI32Eqz is the 'i32.eqz' instruction.
InstructionI32GeS is the 'i32.ge_s' instruction.
InstructionI32GeU is the 'i32.ge_u' instruction.
InstructionI32GtS is the 'i32.gt_s' instruction.
InstructionI32GtU is the 'i32.gt_u' instruction.
InstructionI32LeS is the 'i32.le_s' instruction.
InstructionI32LeU is the 'i32.le_u' instruction.
InstructionI32LtS is the 'i32.lt_s' instruction.
InstructionI32LtU is the 'i32.lt_u' instruction.
InstructionI32Mul is the 'i32.mul' instruction.
InstructionI32Ne is the 'i32.ne' instruction.
InstructionI32Or is the 'i32.or' instruction.
InstructionI32Popcnt is the 'i32.popcnt' instruction.
InstructionI32RemS is the 'i32.rem_s' instruction.
InstructionI32RemU is the 'i32.rem_u' instruction.
InstructionI32Rotl is the 'i32.rotl' instruction.
InstructionI32Rotr is the 'i32.rotr' instruction.
InstructionI32Shl is the 'i32.shl' instruction.
InstructionI32ShrS is the 'i32.shr_s' instruction.
InstructionI32ShrU is the 'i32.shr_u' instruction.
InstructionI32Sub is the 'i32.sub' instruction.
InstructionI32WrapI64 is the 'i32.wrap_i64' instruction.
InstructionI32Xor is the 'i32.xor' instruction.
InstructionI64Add is the 'i64.add' instruction.
InstructionI64And is the 'i64.and' instruction.
InstructionI64Clz is the 'i64.clz' instruction.
InstructionI64Const is the 'i64.const' instruction.
InstructionI64Ctz is the 'i64.ctz' instruction.
InstructionI64DivS is the 'i64.div_s' instruction.
InstructionI64DivU is the 'i64.div_u' instruction.
InstructionI64Eq is the 'i64.eq' instruction.
InstructionI64Eqz is the 'i64.eqz' instruction.
InstructionI64ExtendI32S is the 'i64.extend_i32_s' instruction.
InstructionI64ExtendI32U is the 'i64.extend_i32_u' instruction.
InstructionI64GeS is the 'i64.ge_s' instruction.
InstructionI64GeU is the 'i64.ge_u' instruction.
InstructionI64GtS is the 'i64.gt_s' instruction.
InstructionI64GtU is the 'i64.gt_u' instruction.
InstructionI64LeS is the 'i64.le_s' instruction.
InstructionI64LeU is the 'i64.le_u' instruction.
InstructionI64LtS is the 'i64.lt_s' instruction.
InstructionI64LtU is the 'i64.lt_u' instruction.
InstructionI64Mul is the 'i64.mul' instruction.
InstructionI64Ne is the 'i64.ne' instruction.
InstructionI64Or is the 'i64.or' instruction.
InstructionI64Popcnt is the 'i64.popcnt' instruction.
InstructionI64RemS is the 'i64.rem_s' instruction.
InstructionI64RemU is the 'i64.rem_u' instruction.
InstructionI64Rotl is the 'i64.rotl' instruction.
InstructionI64Rotr is the 'i64.rotr' instruction.
InstructionI64Shl is the 'i64.shl' instruction.
InstructionI64ShrS is the 'i64.shr_s' instruction.
InstructionI64ShrU is the 'i64.shr_u' instruction.
InstructionI64Sub is the 'i64.sub' instruction.
InstructionI64Xor is the 'i64.xor' instruction.
InstructionIf is the 'if' instruction.
InstructionLocalGet is the 'local.get' instruction.
InstructionLocalSet is the 'local.set' instruction.
InstructionLocalTee is the 'local.tee' instruction.
InstructionLoop is the 'loop' instruction.
InstructionNop is the 'nop' instruction.
InstructionRefFunc is the 'ref.func' instruction.
InstructionRefIsNull is the 'ref.is_null' instruction.
InstructionRefNull is the 'ref.null' instruction.
InstructionReturn is the 'return' instruction.
InstructionSelect is the 'select' instruction.
InstructionUnreachable is the 'unreachable' instruction.
InvalidBlockSecondInstructionsError is returned when the WASM binary specifies or the writer is given a second set of instructions in a block that is not allowed to have it (only the 'if' instruction may have it).
InvalidBlockTypeTypeIndexError is returned when the WASM binary specifies an invalid type index as a block type.
InvalidCodeSectionCompressedLocalsCountError is returned when the WASM binary specifies an invalid local type in the code section.
InvalidCodeSectionFunctionCountError is returned when the WASM binary specifies an invalid function count in the code section.
InvalidCodeSectionLocalsCountError is returned when the WASM binary specifies an invalid locals count in the code section.
InvalidCodeSectionLocalTypeError is returned when the WASM binary specifies an invalid local type in the code section.
InvalidCodeSizeError is returned when the WASM binary specifies an invalid code size in the code section.
InvalidDataSectionInitByteCountError is returned when the WASM binary specifies an invalid init byte count in the data section.
InvalidDataSectionMemoryIndexError is returned when the WASM binary specifies an invalid memory index in the data section.
InvalidDataSectionSegmentCountError is returned when the WASM binary specifies an invalid count in the data section.
InvalidDataSegmentError is returned when the WASM binary specifies invalid segment in the data section.
InvalidDuplicateSectionError is returned when the WASM binary specifies a duplicate section.
InvalidExportError is returned when the WASM binary specifies invalid export in the export section.
InvalidExportIndicatorError is returned when the WASM binary specifies an invalid type indicator in the export section.
InvalidExportSectionExportCountError is returned when the WASM binary specifies an invalid count in the export section.
InvalidExportSectionIndexError is returned when the WASM binary specifies an invalid index in the export section.
InvalidFunctionCodeError is returned when the WASM binary specifies invalid code for a function in the code section.
InvalidFunctionSectionFunctionCountError is returned when the WASM binary specifies an invalid count in the function section.
InvalidFunctionSectionTypeIndexError is returned when the WASM binary specifies an invalid type index in the function section.
InvalidFuncTypeIndicatorError is returned when the WASM binary specifies an invalid function type indicator.
InvalidFuncTypeParameterCountError is returned when the WASM binary specifies an invalid func type parameter count.
InvalidFuncTypeParameterTypeError is returned when the WASM binary specifies an invalid function type parameter type.
InvalidFuncTypeResultCountError is returned when the WASM binary specifies an invalid func type result count.
InvalidFuncTypeResultTypeError is returned when the WASM binary specifies an invalid function type result type.
InvalidImportError is returned when the WASM binary specifies invalid import in the import section.
InvalidImportIndicatorError is returned when the WASM binary specifies an invalid type indicator in the import section.
InvalidImportSectionImportCountError is returned when the WASM binary specifies an invalid count in the import section.
InvalidImportSectionTypeIndexError is returned when the WASM binary specifies an invalid type index in the import section.
InvalidInstructionArgumentError is returned when the WASM binary specifies an invalid argument for an instruction in the code section.
InvalidInstructionVectorArgumentCountError is returned when the WASM binary specifies an invalid count for a vector argument of an instruction.
InvalidLimitIndicatorError is returned when the WASM binary specifies an invalid limit indicator.
InvalidLimitMaxError is returned when the WASM binary specifies an invalid limit maximum.
InvalidLimitMinError is returned when the WASM binary specifies an invalid limit minimum.
InvalidMagicError is returned when the WASM binary does not start with the magic byte sequence.
InvalidMemoryError is returned when the WASM binary specifies invalid memory in the memory section.
InvalidMemorySectionMemoryCountError is returned when the WASM binary specifies an invalid count in the memory section.
InvalidNameError is returned the WASM binary specifies an invalid name.
InvalidNameLengthError is returned the WASM binary specifies an invalid name length.
InvalidNonUTF8NameError is returned when the WASM binary specifies or the writer is given a name which is not properly UTF-8 encoded.
InvalidOpcodeError is returned when the WASM binary specifies an invalid opcode in the code section.
InvalidSectionIDError is returned when the WASM binary specifies an invalid section ID.
InvalidSectionOrderError is returned when the WASM binary specifies a non-custom section out-of-order.
InvalidSectionSizeError is returned when the WASM binary specifies an invalid section size.
InvalidStartSectionFunctionIndexError is returned when the WASM binary specifies an invalid function index in the start section.
InvalidTypeSectionTypeCountError is returned when the WASM binary specifies an invalid count in the type section.
InvalidValTypeError is returned when the WASM binary specifies an invalid value type.
InvalidMagicError is returned when the WASM binary does not have the expected version.
Memory represents a memory.
MemoryExport represents the export of a memory.
MissingEndInstructionError is returned when the WASM binary misses an end instruction for a function in the code section.
Module represents a module.
ModuleBuilder allows building modules.
No description provided by the author
WASMReader allows reading WASM binaries.
WASMWriter allows writing WASM binaries.

# Interfaces

No description provided by the author
ExportDescriptor represents an export (e.g.
Instruction represents an instruction in the code of a WASM binary.

# Type aliases

ValueType is the type of a value.