2019-03-18 16:43:28 +00:00
|
|
|
{
|
2019-03-26 16:35:26 +00:00
|
|
|
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-03-18 16:43:28 +00:00
|
|
|
}
|
|
|
|
// ----
|
2020-03-17 22:31:56 +00:00
|
|
|
// step: redundantAssignEliminator
|
|
|
|
//
|
2019-03-18 16:43:28 +00:00
|
|
|
// {
|
2019-03-26 16:35:26 +00:00
|
|
|
// let x
|
2019-05-08 10:41:19 +00:00
|
|
|
// for { } calldataload(0) { mstore(x, 0x42) }
|
2019-03-18 16:43:28 +00:00
|
|
|
// {
|
|
|
|
// if callvalue()
|
|
|
|
// {
|
|
|
|
// x := 2
|
|
|
|
// continue
|
|
|
|
// }
|
|
|
|
// x := 3
|
|
|
|
// }
|
|
|
|
// }
|