Merge remote-tracking branch 'origin/develop' into breaking

This commit is contained in:
chriseth
2020-12-16 16:56:45 +01:00
8 changed files with 81 additions and 23 deletions
@@ -50,7 +50,9 @@ contract MyConc{
}
}
// ====
// SMTIgnoreCex: yes
// ----
// Warning 2519: (773-792): This declaration shadows an existing declaration.
// Warning 2018: (1009-1086): Function state mutability can be restricted to view
// Warning 4984: (985-1002): CHC: Overflow (resulting value larger than 2**256 - 1) happens here.\nCounterexample:\nA = 1, should_be_constant = 0, should_be_constant_2 = 2, not_constant = 0, not_constant_2 = 115792089237316195423570985008687907853269984665640564039457584007913129639926, not_constant_3 = 0\n\nTransaction trace:\nconstructor()
// Warning 4984: (985-1002): CHC: Overflow (resulting value larger than 2**256 - 1) happens here.
@@ -0,0 +1,15 @@
pragma experimental SMTChecker;
contract C {
uint constant x = 2;
uint constant y = x ** 10;
function f() public view {
assert(y == 2 ** 10);
assert(y == 1024);
assert(y == 14); // should fail
}
}
// ----
// Warning 2018: (98-206): Function state mutability can be restricted to pure
// Warning 6328: (172-187): CHC: Assertion violation happens here.\nCounterexample:\nx = 2, y = 1024\n\n\n\nTransaction trace:\nconstructor()\nState: x = 2, y = 1024\nf()
@@ -0,0 +1,13 @@
pragma experimental SMTChecker;
contract C {
uint constant DEPOSIT_CONTRACT_TREE_DEPTH = 32;
uint constant MAX_DEPOSIT_COUNT = 2**DEPOSIT_CONTRACT_TREE_DEPTH - 1;
function f() public pure {
assert(DEPOSIT_CONTRACT_TREE_DEPTH == 32);
assert(MAX_DEPOSIT_COUNT == 4294967295);
assert(MAX_DEPOSIT_COUNT == 2); // should fail
}
}
// ----
// Warning 6328: (284-314): CHC: Assertion violation happens here.\nCounterexample:\nDEPOSIT_CONTRACT_TREE_DEPTH = 32, MAX_DEPOSIT_COUNT = 4294967295\n\n\n\nTransaction trace:\nconstructor()\nState: DEPOSIT_CONTRACT_TREE_DEPTH = 32, MAX_DEPOSIT_COUNT = 4294967295\nf()
@@ -1,10 +1,10 @@
contract TimelockUpgrade {
function confirmUpgrade() external {
uint256 m;
uint256 d;
(/*year*/,/*month*/,d/*yad*/,m/*hour*/,/*minute*/,/*second*/) = BokkyDateTime.timestampToDateTime(block.timestamp);
}
}
contract TimelockUpgrade {
function confirmUpgrade() external {
uint256 m;
uint256 d;
(/*year*/,/*month*/,d/*yad*/,m/*hour*/,/*minute*/,/*second*/) = BokkyDateTime.timestampToDateTime(block.timestamp);
}
}
// ----
// ParserError 8936: (128-139): Mismatching directional override markers in comment or string literal.
// ParserError 8936: (124-135): Mismatching directional override markers in comment or string literal.