mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
20 lines
367 B
Solidity
20 lines
367 B
Solidity
pragma experimental SMTChecker;
|
|
|
|
contract Simple {
|
|
uint[] a;
|
|
function f(uint n) public {
|
|
uint i;
|
|
while (i < n)
|
|
{
|
|
a[i] = i;
|
|
++i;
|
|
}
|
|
require(n > 1);
|
|
// Assertion is safe but current solver version cannot solve it.
|
|
// Keep test for next solver release.
|
|
assert(a[n-1] > a[n-2]);
|
|
}
|
|
}
|
|
// ----
|
|
// Warning: (273-296): Assertion violation happens here
|