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

Method get_wasm_local

winch/codegen/src/frame/mod.rs:260–264  ·  view source on GitHub ↗

Get the [`LocalSlot`] for a WebAssembly local. This method assumes that the index is bound to u32::MAX, representing the index space for WebAssembly locals. # Panics This method panics if the index is not associated to a valid WebAssembly local.

(&self, index: u32)

Source from the content-addressed store, hash-verified

258 /// This method panics if the index is not associated to a valid WebAssembly
259 /// local.
260 pub fn get_wasm_local(&self, index: u32) -> &LocalSlot {
261 self.wasm_locals
262 .get(index as usize)
263 .unwrap_or_else(|| panic!(" Expected WebAssembly local at slot: {index}"))
264 }
265
266 /// Get the [`LocalSlot`] for a special local.
267 ///

Callers 5

visit_local_getMethod · 0.80
get_local_addressMethod · 0.80
pop_to_addrMethod · 0.80
move_val_to_regMethod · 0.80
spill_implMethod · 0.80

Calls 1

getMethod · 0.45

Tested by

no test coverage detected