Module Mavryk_wasmer.Exports

type t

WebAssembly module instance exports

val from_instance : Instance.t -> t

from_intance instance extracts the exports from the given instance.

val delete : t -> unit

delete exports cleans up the exports collection to free its associated objects. You must not use previously extracted export objects after calling call.

val fn : t -> string -> 'a fn -> 'a

fn exports name typ looks for a function called name and type checks it against typ.

val mem : t -> string -> Memory.t

mem exports name looks for a memory called name.

val mem0 : t -> Memory.t

mem0 exports gives you the first memory instance it finds. The order of memory instances is not specified and may change in the future. This function should be avoided unless you know the module in question only exports one memory instance.