solidity/test/libsolidity/smtCheckerTests/functions/functions_recursive_indirect.sol
2021-10-26 11:30:30 +02:00

27 lines
304 B
Solidity

contract C
{
uint a;
function f() public {
if (a > 0)
{
a = a - 1;
g();
}
else
assert(a == 0);
}
function g() public {
if (a > 0)
{
a = a - 1;
f();
}
else
assert(a == 0);
}
}
// ====
// SMTEngine: all
// ----
// Info 1180: Contract invariant(s) for :C:\n(a <= 0)\n