solidity/test/libsolidity/smtCheckerTests/modifiers/modifier_two_invocations.sol

20 lines
246 B
Solidity
Raw Normal View History

2019-03-11 20:06:28 +00:00
pragma experimental SMTChecker;
contract C
{
uint x;
modifier m {
// Condition is always true for the second invocation.
require(x > 0);
require(x < 10000);
_;
assert(x > 1);
}
function f() m m public {
x = x + 1;
}
}
// ----