forked from ethereum-optimism/optimism
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #88 from defi-wonderland/fix/crosschain-merge-conf…
…licts fix: crosschain merge conflicts
- Loading branch information
Showing
216 changed files
with
2,511 additions
and
2,536 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
rules: | ||
- id: sol-safety-deployutils-args | ||
languages: [solidity] | ||
severity: ERROR | ||
message: _args parameter should be wrapped with DeployUtils.encodeConstructor | ||
pattern-regex: DeployUtils\.(create1|create2|create1AndSave|create2AndSave)\s*\(\s*\{[^}]*?_args\s*:\s*(?!\s*DeployUtils\.encodeConstructor\()\s*[^}]*?\}\s*\) | ||
|
||
- id: sol-style-input-arg-fmt | ||
languages: [solidity] | ||
severity: ERROR | ||
message: Named inputs to functions must be prepended with an underscore | ||
pattern-regex: function\s+\w+\s*\(\s*([^)]*?\b\w+\s+(?!_)(?!memory\b)(?!calldata\b)(?!storage\b)(?!payable\b)\w+\s*(?=,|\))) | ||
paths: | ||
exclude: | ||
- op-chain-ops/script/testdata/scripts/ScriptExample.s.sol | ||
- packages/contracts-bedrock/scripts/libraries/Solarray.sol | ||
- packages/contracts-bedrock/scripts/interfaces/IGnosisSafe.sol | ||
- packages/contracts-bedrock/src/universal/interfaces/IWETH.sol | ||
- packages/contracts-bedrock/src/universal/WETH98.sol | ||
- packages/contracts-bedrock/src/L2/interfaces/ISuperchainWETH.sol | ||
- packages/contracts-bedrock/src/L2/SuperchainWETH.sol | ||
- packages/contracts-bedrock/src/governance/interfaces/IGovernanceToken.sol | ||
- packages/contracts-bedrock/src/governance/GovernanceToken.sol | ||
|
||
- id: sol-style-return-arg-fmt | ||
languages: [solidity] | ||
severity: ERROR | ||
message: Named return arguments to functions must be appended with an underscore | ||
pattern-regex: returns\s*(\w+\s*)?\(\s*([^)]*?\b\w+\s+(?!memory\b)(?!calldata\b)(?!storage\b)(?!payable\b)\w+(?<!_)\s*(?=,|\))) | ||
paths: | ||
exclude: | ||
- op-chain-ops/script/testdata/scripts/ScriptExample.s.sol | ||
- packages/contracts-bedrock/scripts/libraries/Solarray.sol | ||
- packages/contracts-bedrock/scripts/interfaces/IGnosisSafe.sol | ||
- packages/contracts-bedrock/src/dispute/interfaces/IPermissionedDisputeGame.sol | ||
- packages/contracts-bedrock/src/dispute/interfaces/IFaultDisputeGame.sol | ||
|
||
- id: sol-style-doc-comment | ||
languages: [solidity] | ||
severity: ERROR | ||
message: Javadoc-style comments are not allowed, use `///` style doc comments instead | ||
pattern-regex: (\/\*\*\n(\s+\*\s.*\n)+\s+\*\/) | ||
|
||
- id: sol-expectrevert-no-args | ||
languages: [solidity] | ||
severity: ERROR | ||
message: vm.expectRevert() must specify the revert reason | ||
patterns: | ||
- pattern: vm.expectRevert() | ||
|
||
- id: sol-style-malformed-require | ||
languages: [solidity] | ||
severity: ERROR | ||
message: Require statement style is malformed | ||
patterns: | ||
- pattern: require(..., $ERR); | ||
- pattern-not: require($ERR); | ||
- focus-metavariable: $ERR | ||
- pattern-not-regex: \"(\w+:\s[^"]+)\" | ||
- pattern-not-regex: string\.concat\(\"(\w+:\s[^"]+)\"\,[^"]+\) | ||
- pattern-not-regex: \"([a-zA-Z0-9\s]+-[a-zA-Z0-9\s]+)\" | ||
- pattern-not-regex: \"([a-zA-Z0-9\s]+-[a-zA-Z0-9\s]+-[a-zA-Z0-9\s]+)\" | ||
paths: | ||
exclude: | ||
- packages/contracts-bedrock/src/libraries/Bytes.sol | ||
- packages/contracts-bedrock/src/legacy/LegacyMintableERC20.sol | ||
- packages/contracts-bedrock/src/cannon/MIPS.sol | ||
- packages/contracts-bedrock/src/cannon/MIPS2.sol | ||
- packages/contracts-bedrock/src/cannon/libraries/MIPSMemory.sol | ||
- packages/contracts-bedrock/src/cannon/libraries/MIPSInstructions.sol | ||
|
||
- id: sol-style-malformed-revert | ||
languages: [solidity] | ||
severity: ERROR | ||
message: Revert statement style is malformed | ||
patterns: | ||
- pattern: revert($MSG); | ||
- pattern-not: revert $ERR(...); | ||
- focus-metavariable: $MSG | ||
- pattern-not-regex: \"(\w+:\s[^"]+)\" | ||
paths: | ||
exclude: | ||
- packages/contracts-bedrock/src/cannon/libraries/MIPSInstructions.sol |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.