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

23 lines
348 B
Plaintext
Raw Normal View History

2018-10-23 13:55:48 +00:00
{
let c
let d
c := calldataload(0)
d := 1
if c {
d := 2
}
// This enforces that none of the assignments above can be removed.
mstore(0, d)
}
// ----
// step: redundantAssignEliminator
//
2018-10-23 13:55:48 +00:00
// {
// let c
// let d
// c := calldataload(0)
// d := 1
// if c { d := 2 }
2018-10-23 13:55:48 +00:00
// mstore(0, d)
// }