2018-10-15 10:51:50 +00:00
|
|
|
// This tests that splitting the expression inside the condition works properly.
|
2018-10-11 15:14:59 +00:00
|
|
|
{
|
|
|
|
if gt(f(mload(1)), mload(0)) {
|
|
|
|
sstore(0, 2)
|
|
|
|
}
|
|
|
|
function f(a) -> r {
|
|
|
|
a := mload(a)
|
|
|
|
r := add(a, calldatasize())
|
|
|
|
}
|
|
|
|
}
|
2019-04-01 14:33:46 +00:00
|
|
|
// ====
|
|
|
|
// step: fullInliner
|
2018-10-11 15:14:59 +00:00
|
|
|
// ----
|
|
|
|
// {
|
|
|
|
// {
|
2018-10-02 08:46:59 +00:00
|
|
|
// let _2 := mload(0)
|
2019-03-04 17:03:30 +00:00
|
|
|
// let a_10 := mload(1)
|
|
|
|
// let r_11 := 0
|
|
|
|
// a_10 := mload(a_10)
|
|
|
|
// r_11 := add(a_10, calldatasize())
|
|
|
|
// if gt(r_11, _2)
|
2018-10-11 15:14:59 +00:00
|
|
|
// {
|
|
|
|
// sstore(0, 2)
|
|
|
|
// }
|
|
|
|
// }
|
|
|
|
// function f(a) -> r
|
|
|
|
// {
|
|
|
|
// a := mload(a)
|
|
|
|
// r := add(a, calldatasize())
|
|
|
|
// }
|
|
|
|
// }
|