package wasmer

  1. Overview
  2. Docs

Module Val.VSource

Sourcetype data_type = t Ctypes.structure
Sourceval data_type : data_type Ctypes.typ
Sourceval name : string

The structure base name (without the wasm_ prefix and _vec_t suffix)

Sourcetype owning_struct = s

Vectors always take ownership of their elements.

Sourceval grab_ownership : owning_struct -> data_type

Take away the ownership.

Sourceval to_dependent : data_type -> ((unit -> object_state) * object_state dependent_update_func) -> owning_struct

Transform an element of the vector back to a pointer, which ownership is dependent on this vector.

  • parameter obj

    The element

  • parameter arg

    The ownership callbacks

  • returns

    The new owning structure

OCaml

Innovation. Community. Security.