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

Method add_trap

cranelift/codegen/src/machinst/buffer.rs:1745–1750  ·  view source on GitHub ↗

Add a trap record at the current offset.

(&mut self, code: TrapCode)

Source from the content-addressed store, hash-verified

1743
1744 /// Add a trap record at the current offset.
1745 pub fn add_trap(&mut self, code: TrapCode) {
1746 self.traps.push(MachTrap {
1747 offset: self.data.len() as CodeOffset,
1748 code,
1749 });
1750 }
1751
1752 /// Add a call-site record at the current offset.
1753 pub fn add_call_site(&mut self) {

Callers 2

metadata_recordsFunction · 0.45

Calls 2

pushMethod · 0.45
lenMethod · 0.45

Tested by 1

metadata_recordsFunction · 0.36