MCPcopy Create free account
hub / github.com/bytecodealliance/wasmtime / anyref

Method anyref

crates/wasmtime/src/runtime/values.rs:429–435  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

427 /// If this is a non-null `anyref`, then `Some(Some(..))` is returned.
428 #[inline]
429 pub fn anyref(&self) -> Option<Option<&Rooted<AnyRef>>> {
430 match self {
431 Val::AnyRef(None) => Some(None),
432 Val::AnyRef(Some(e)) => Some(Some(e)),
433 _ => None,
434 }
435 }
436
437 /// Returns the underlying `anyref` value of this `Val`, panicking if it's the
438 /// wrong type.

Callers 1

unwrap_anyrefMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected