Wasmtime
wasmtime_anyref Struct Reference

A WebAssembly value in the any hierarchy of GC types. More...

#include <val.h>

Data Fields

uint64_t store_id
 
uint32_t __private1
 Internal to Wasmtime.
 
uint32_t __private2
 Internal to Wasmtime.
 

Detailed Description

A WebAssembly value in the any hierarchy of GC types.

This structure represents an anyref that WebAssembly can create and pass back to the host. The host can also create values to pass to a guest.

Note that this structure does not itself contain the data that it refers to. Instead to contains metadata to point back within a wasmtime_context_t, so referencing the internal data requires using a wasmtime_context_t.

Anyref values are required to be explicitly unrooted via wasmtime_anyref_unroot to enable them to be garbage-collected.

Null anyref values are represented by this structure and can be tested and created with the wasmtime_anyref_is_null and wasmtime_anyref_set_null functions.

Field Documentation

◆ store_id

uint64_t wasmtime_anyref::store_id

Internal metadata tracking within the store, embedders should not configure or modify these fields.


The documentation for this struct was generated from the following file: