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

Method pop_i32_const

winch/codegen/src/codegen/context.rs:438–450  ·  view source on GitHub ↗

Returns the i32 const on top of the stack or None if there isn't one.

(&mut self)

Source from the content-addressed store, hash-verified

436
437 /// Returns the i32 const on top of the stack or None if there isn't one.
438 pub fn pop_i32_const(&mut self) -> Option<i32> {
439 let top = self.stack.peek().expect("value at stack top");
440
441 if top.is_i32_const() {
442 let val = self
443 .stack
444 .pop_i32_const()
445 .expect("i32 const value at stack top");
446 Some(val)
447 } else {
448 None
449 }
450 }
451
452 /// Returns the i64 const on top of the stack or None if there isn't one.
453 pub fn pop_i64_const(&mut self) -> Option<i64> {

Callers 4

splatMethod · 0.45
i32_shiftMethod · 0.45
i32_binopMethod · 0.45
replace_lane_opMethod · 0.45

Calls 3

is_i32_constMethod · 0.80
expectMethod · 0.45
peekMethod · 0.45

Tested by

no test coverage detected