solidity/test/libyul/yulOptimizerTests/redundantAssignEliminator/for_continue_3.yul

29 lines
543 B
Plaintext
Raw Normal View History

{
let x
// Can be removed, because x is not used after the loop.
x := 1
for { } calldataload(0) { mstore(x, 0x42) }
{
if callvalue() {
x := 2 // is preserved because of continue stmt below.
continue
}
x := 3
}
}
2019-04-01 14:33:46 +00:00
// ====
// step: redundantAssignEliminator
// ----
// {
// let x
// for { } calldataload(0) { mstore(x, 0x42) }
// {
// if callvalue()
// {
// x := 2
// continue
// }
// x := 3
// }
// }