class

Wasmer::Value

Inherits Reference / Object

WebAssembly computations manipulate values of basic value types:

  • Integer (32 or 64 bit width)
  • Floating-point (32 or 64 bit width)
  • Vectors (128 bits, with 32 or 64 bit lanes)

See Also Specification: https://webassembly.github.io/spec/core/exec/runtime.html#values

Constructors

new(val : Number, kind : ValueKind)
Source
new(value : Int)
Source
new(value : Float)
Source

Instance methods

as_f

Returns the Value's value as a native Crystal Float64 raises otherwise

Source
as_f32

Returns the Value's value as a native Crystal Float32 raises otherwise

Source
as_i

Returns the Value's value as a native Crystal Int32 raises otherwise

Source
as_i64

Returns the Value's value as a native Crystal Int64 raises otherwise

Source
kind
Source
unwrap

Returns the Value's value as a native Crystal value

Source