MCPcopy Create free account
hub / github.com/explodingcamera/tinywasm / patch_jump_if_zero

Method patch_jump_if_zero

crates/parser/src/visit.rs:631–635  ·  view source on GitHub ↗
(&mut self, jump_ip: usize, target: usize)

Source from the content-addressed store, hash-verified

629 }
630
631 fn patch_jump_if_zero(&mut self, jump_ip: usize, target: usize) {
632 if let Instruction::JumpIfZero32(ip) = &mut self.instructions[jump_ip] {
633 *ip = target as u32;
634 }
635 }
636
637 fn label_keep_counts(label_types: &[wasmparser::ValType]) -> (u16, u16, u16) {
638 let (mut c32, mut c64, mut c128) = (0, 0, 0);

Callers 3

visit_elseMethod · 0.80
visit_br_ifMethod · 0.80
patch_end_jumpsMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected