Skip to content

Commit

Permalink
Workaround for fixing voteYays_revert
Browse files Browse the repository at this point in the history
  • Loading branch information
sunbreak1211 committed Oct 8, 2024
1 parent 0f38292 commit 48e7a8e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 14 deletions.
16 changes: 2 additions & 14 deletions certora/VoteDelegate.conf
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,8 @@
"certora/harness/ChiefMock.sol",
"certora/harness/PollingMock.sol"
],
"solc_map": {
"VoteDelegate": "solc-0.8.21",
"GovMock": "solc-0.8.21",
"IouMock": "solc-0.8.21",
"ChiefMock": "solc-0.8.21",
"PollingMock": "solc-0.8.21"
},
"solc_optimize_map": {
"VoteDelegate": "200",
"GovMock": "200",
"IouMock": "200",
"ChiefMock": "200",
"PollingMock": "200"
},
"solc": "solc-0.8.21",
"solc_optimize": "200",
"link": [
"VoteDelegate:gov=GovMock",
"VoteDelegate:chief=ChiefMock",
Expand Down
4 changes: 4 additions & 0 deletions certora/VoteDelegate.spec
Original file line number Diff line number Diff line change
Expand Up @@ -223,6 +223,10 @@ rule voteYays(address[] yays) {
rule voteYays_revert(address[] yays) {
env e;

require(forall uint256 i. (
i >= yays.length || to_mathint(yays[i]) < 2^160
));

address delegate = delegate();

vote@withrevert(e, yays);
Expand Down

0 comments on commit 48e7a8e

Please sign in to comment.