solidity/test/libsolidity/smtCheckerTests/array_members/push_overflow_2_safe.sol
2021-04-08 21:03:39 +02:00

14 lines
228 B
Solidity

contract C {
uint256[] x;
function f(uint256 l) public {
require(x.length == 0);
x.push(42);
x.push(84);
for(uint256 i = 0; i < l; ++i)
x.push(23);
assert(x[0] == 42 || x[0] == 23);
}
}
// ====
// SMTEngine: all