Skip to content

Commit 68ce752

Browse files
committed
fix local.tee translation bug
1 parent 2d8dc70 commit 68ce752

File tree

1 file changed

+4
-0
lines changed
  • crates/wasmi/src/engine/translator/func2

1 file changed

+4
-0
lines changed

crates/wasmi/src/engine/translator/func2/mod.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1096,6 +1096,10 @@ impl FuncTranslator {
10961096
//
10971097
// Note: This does not require any preservation since it won't change
10981098
// the value of `local $n`.
1099+
if push_result {
1100+
// Need to push back input before we exit.
1101+
self.stack.push_operand(input.into())?;
1102+
}
10991103
return Ok(());
11001104
}
11011105
}

0 commit comments

Comments
 (0)