solidity/test/libsolidity/semanticTests/viaYul/conditional/conditional_with_assignment.sol
Daniel Kirchner a8f7c69c47 Adjust tests.
2021-09-13 20:41:40 +02:00

16 lines
322 B
Solidity

contract A {
function f() public pure returns (uint, uint, uint, uint) {
uint y1 = 1;
uint y2 = 1;
uint x = 3 < 0 ? y1 = 3 : 6;
uint z = 3 < 10 ? y2 = 5 : 6;
return (x, y1, y2, z);
}
}
// ====
// requiresYulOptimizer: minimalStack
// compileToEwasm: also
// compileViaYul: also
// ----
// f() -> 6, 1, 5, 5