chore(certora): upgrade certora to 7.0.7

This upgrade certora-cli on CI to version 7.0.7 which no longer requires
the usage of the `STORAGE` keyword in storage hooks.
This commit is contained in:
r4bbit 2024-03-18 12:12:02 +01:00
parent a2cf75787f
commit af4410677b
No known key found for this signature in database
GPG Key ID: E95F1E9447DC91A9
2 changed files with 3 additions and 3 deletions

View File

@ -135,7 +135,7 @@ jobs:
with: { java-version: "11", java-package: jre } with: { java-version: "11", java-package: jre }
- name: Install Certora CLI - name: Install Certora CLI
run: pip3 install certora-cli==6.3.1 run: pip3 install certora-cli==7.0.7
- name: Install Solidity - name: Install Solidity
run: | run: |

View File

@ -16,11 +16,11 @@ ghost mathint sumOfBalances {
init_state axiom sumOfBalances == 0; init_state axiom sumOfBalances == 0;
} }
hook Sstore _balances[KEY address addr] uint256 newValue (uint256 oldValue) STORAGE { hook Sstore _balances[KEY address addr] uint256 newValue (uint256 oldValue) {
sumOfBalances = sumOfBalances - oldValue + newValue; sumOfBalances = sumOfBalances - oldValue + newValue;
} }
hook Sload uint256 balance _balances[KEY address addr] STORAGE { hook Sload uint256 balance _balances[KEY address addr] {
require sumOfBalances >= to_mathint(balance); require sumOfBalances >= to_mathint(balance);
} }