MCPcopy Create free account
hub / github.com/WasmEdge/WasmEdge / runRefI31Op

Method runRefI31Op

lib/executor/engine/refInstr.cpp:389–394  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

387}
388
389Expect<void> Executor::runRefI31Op(ValVariant &Val) const noexcept {
390 uint32_t RefNum = (Val.get<uint32_t>() & 0x7FFFFFFFU) | 0x80000000U;
391 Val = RefVariant(ValType(TypeCode::Ref, TypeCode::I31Ref),
392 reinterpret_cast<void *>(static_cast<uint64_t>(RefNum)));
393 return {};
394}
395
396Expect<void> Executor::runI31GetOp(ValVariant &Val,
397 const AST::Instruction &Instr,

Callers

nothing calls this directly

Calls 2

RefVariantClass · 0.85
ValTypeClass · 0.85

Tested by

no test coverage detected