Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Certora] Move munged folder up #100

Open
wants to merge 4 commits into
base: colin@verif/delegation
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 9 additions & 7 deletions certora/Makefile
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
munged: $(wildcard ../src/*.sol) applyMunging.patch
@rm -rf munged
@cp -r ../src munged
@patch -p0 -d munged < applyMunging.patch
munged: ../munged

../munged: $(wildcard ../src/*.sol) applyMunging.patch
@rm -rf ../munged
@cp -r ../src ../munged
@patch -p0 -d ../munged < applyMunging.patch

record:
diff -ruN ../src munged | sed 's+ \.\./src/+ +g' | sed 's+munged/++g' > applyMunging.patch
diff -ruN ../src ../munged | sed 's+ \.\./src/+ +g' | sed 's+ \.\./munged/+ +g' > applyMunging.patch

clean:
rm -rf munged
rm -rf ../munged

.PHONY: help clean # do not add munged here, as it is useful to protect munged edits
.PHONY: clean record munged # Do not add ../munged here, as it is useful to protect munged edits
47 changes: 3 additions & 44 deletions certora/applyMunging.patch
Original file line number Diff line number Diff line change
@@ -1,26 +1,6 @@
diff -ruN DelegationToken.sol DelegationToken.sol
--- DelegationToken.sol 2024-11-14 11:00:56.877231237 +0100
+++ DelegationToken.sol 2024-11-20 16:18:55.750677310 +0100
@@ -4,14 +4,14 @@
import {IDelegation, Signature, Delegation} from "./interfaces/IDelegation.sol";

import {ERC20PermitUpgradeable} from
- "../lib/openzeppelin-contracts-upgradeable/contracts/token/ERC20/extensions/ERC20PermitUpgradeable.sol";
+ "../../lib/openzeppelin-contracts-upgradeable/contracts/token/ERC20/extensions/ERC20PermitUpgradeable.sol";
import {ECDSA} from
- "../lib/openzeppelin-contracts-upgradeable/lib/openzeppelin-contracts/contracts/utils/cryptography/ECDSA.sol";
+ "../../lib/openzeppelin-contracts-upgradeable/lib/openzeppelin-contracts/contracts/utils/cryptography/ECDSA.sol";
import {Ownable2StepUpgradeable} from
- "../lib/openzeppelin-contracts-upgradeable/contracts/access/Ownable2StepUpgradeable.sol";
-import {UUPSUpgradeable} from "../lib/openzeppelin-contracts-upgradeable/contracts/proxy/utils/UUPSUpgradeable.sol";
+ "../../lib/openzeppelin-contracts-upgradeable/contracts/access/Ownable2StepUpgradeable.sol";
+import {UUPSUpgradeable} from "../../lib/openzeppelin-contracts-upgradeable/contracts/proxy/utils/UUPSUpgradeable.sol";
import {ERC1967Utils} from
- "../lib/openzeppelin-contracts-upgradeable/lib/openzeppelin-contracts/contracts/proxy/ERC1967/ERC1967Utils.sol";
+ "../../lib/openzeppelin-contracts-upgradeable/lib/openzeppelin-contracts/contracts/proxy/ERC1967/ERC1967Utils.sol";

/// @title DelegationToken
/// @author Morpho Association
+++ DelegationToken.sol 2024-11-20 16:37:42.398598564 +0100
@@ -44,6 +44,9 @@
mapping(address => uint256) _delegationNonce;
}
Expand Down Expand Up @@ -48,21 +28,9 @@ diff -ruN DelegationToken.sol DelegationToken.sol
}
}
}
diff -ruN interfaces/IOptimismMintableERC20.sol interfaces/IOptimismMintableERC20.sol
--- interfaces/IOptimismMintableERC20.sol 2024-11-14 11:00:56.877231237 +0100
+++ interfaces/IOptimismMintableERC20.sol 2024-11-20 16:30:24.300071161 +0100
@@ -2,7 +2,7 @@
pragma solidity >=0.5.0;

import {IERC165} from
- "../../lib/openzeppelin-contracts-upgradeable/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol";
+ "../../../lib/openzeppelin-contracts-upgradeable/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol";

/// @title IOptimismMintableERC20
/// @author Morpho Association
diff -ruN MorphoTokenEthereum.sol MorphoTokenEthereum.sol
--- MorphoTokenEthereum.sol 2024-11-14 11:00:56.877231237 +0100
+++ MorphoTokenEthereum.sol 2024-11-20 13:29:38.986459880 +0100
+++ MorphoTokenEthereum.sol 2024-11-20 16:37:42.399598538 +0100
@@ -26,16 +26,19 @@
__ERC20Permit_init(NAME);
__Ownable_init(owner);
Expand All @@ -85,16 +53,7 @@ diff -ruN MorphoTokenEthereum.sol MorphoTokenEthereum.sol
}
diff -ruN MorphoTokenOptimism.sol MorphoTokenOptimism.sol
--- MorphoTokenOptimism.sol 2024-11-14 11:00:56.877231237 +0100
+++ MorphoTokenOptimism.sol 2024-11-20 16:19:11.314241653 +0100
@@ -3,7 +3,7 @@

import {IOptimismMintableERC20} from "./interfaces/IOptimismMintableERC20.sol";
import {IERC165} from
- "../lib/openzeppelin-contracts-upgradeable/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol";
+ "../../lib/openzeppelin-contracts-upgradeable/lib/openzeppelin-contracts/contracts/utils/introspection/IERC165.sol";

import {DelegationToken} from "./DelegationToken.sol";

+++ MorphoTokenOptimism.sol 2024-11-20 16:37:42.399598538 +0100
@@ -69,12 +69,14 @@

/// @dev Allows the StandardBridge on this network to mint tokens.
Expand Down
2 changes: 1 addition & 1 deletion certora/confs/DelegationEthereum.conf
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"files": [
"certora/munged/MorphoTokenEthereum.sol"
"munged/MorphoTokenEthereum.sol"
],
"parametric_contracts": [
"MorphoTokenEthereum"
Expand Down
2 changes: 1 addition & 1 deletion certora/confs/DelegationOptimism.conf
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"files": [
"certora/munged/MorphoTokenOptimism.sol"
"munged/MorphoTokenOptimism.sol"
],
"parametric_contracts": [
"MorphoTokenOptimism"
Expand Down