Commit f77c5edd authored by Maurelian's avatar Maurelian Committed by Kelvin Fichter

chore(contracts): Replace solhint linting with prettier

parent d89045b7
......@@ -19,7 +19,6 @@ abstract contract Proxy {
* This function does not return to its internall call site, it will return directly to the external caller.
*/
function _delegate(address implementation) internal virtual {
// solhint-disable-next-line no-inline-assembly
assembly {
// Copy msg.data. We take full control of memory in this inline assembly
// block because it will not return to Solidity code. We overwrite the
......
......@@ -541,7 +541,6 @@ contract CanonicalTransactionChain is ICanonicalTransactionChain, Lib_AddressRes
uint40 lastTimestamp;
uint40 lastBlockNumber;
// solhint-disable max-line-length
assembly {
extraData := shr(40, extraData)
totalElements := and(extraData, 0x000000000000000000000000000000000000000000000000000000FFFFFFFFFF)
......@@ -549,7 +548,6 @@ contract CanonicalTransactionChain is ICanonicalTransactionChain, Lib_AddressRes
lastTimestamp := shr(80, and(extraData, 0x0000000000000000000000000000000000FFFFFFFFFF00000000000000000000))
lastBlockNumber := shr(120, and(extraData, 0x000000000000000000000000FFFFFFFFFF000000000000000000000000000000))
}
// solhint-enable max-line-length
return (
totalElements,
......
......@@ -256,7 +256,6 @@ contract StateCommitmentChain is IStateCommitmentChain, Lib_AddressResolver {
{
bytes27 extraData = batches().getGlobalMetadata();
// solhint-disable max-line-length
uint40 totalElements;
uint40 lastSequencerTimestamp;
assembly {
......@@ -264,7 +263,6 @@ contract StateCommitmentChain is IStateCommitmentChain, Lib_AddressResolver {
totalElements := and(extraData, 0x000000000000000000000000000000000000000000000000000000FFFFFFFFFF)
lastSequencerTimestamp := shr(40, and(extraData, 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF0000000000))
}
// solhint-enable max-line-length
return (
totalElements,
......
......@@ -62,7 +62,6 @@ contract OVM_SequencerFeeVault {
{
require(
address(this).balance >= MIN_WITHDRAWAL_AMOUNT,
// solhint-disable-next-line max-line-length
"OVM_SequencerFeeVault: withdrawal amount must be greater than minimum withdrawal amount"
);
......
......@@ -5,7 +5,6 @@ pragma solidity ^0.8.9;
* @title Lib_PredeployAddresses
*/
library Lib_PredeployAddresses {
// solhint-disable max-line-length
address internal constant L2_TO_L1_MESSAGE_PASSER = 0x4200000000000000000000000000000000000000;
address internal constant L1_MESSAGE_SENDER = 0x4200000000000000000000000000000000000001;
address internal constant DEPLOYER_WHITELIST = 0x4200000000000000000000000000000000000002;
......
......@@ -351,7 +351,6 @@ library Lib_MerkleTrie {
TrieNode[] memory newNodes = new TrieNode[](3);
uint256 totalNewNodes = 0;
// solhint-disable-next-line max-line-length
// Reference: https://github.com/ethereumjs/merkle-patricia-tree/blob/c0a10395aab37d42c175a47114ebfcbd7efcf059/src/baseTrie.ts#L294-L313
bool matchLeaf = false;
if (lastNodeType == NodeType.LeafNode) {
......
......@@ -246,9 +246,7 @@ library Lib_Buffer {
uint40 length;
bytes27 extraData;
assembly {
// solhint-disable-next-line max-line-length
length := and(context, 0x000000000000000000000000000000000000000000000000000000FFFFFFFFFF)
// solhint-disable-next-line max-line-length
extraData := and(context, 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF0000000000)
}
......
......@@ -29,7 +29,7 @@
"pretest:slither": "rm -f @openzeppelin && rm -f @ens && rm -f hardhat && ln -s ../../node_modules/@openzeppelin @openzeppelin && ln -s ../../node_modules/@ens @ens && ln -s ../../node_modules/hardhat hardhat",
"posttest:slither": "rm -f @openzeppelin && rm -f @ens && rm -f hardhat",
"lint:typescript:check": "eslint .",
"lint:contracts:check": "yarn solhint -f table 'contracts/**/*.sol'",
"lint:contracts:check": "yarn prettier --check 'contracts/**/*.sol'",
"lint:check": "yarn lint:contracts:check && yarn lint:typescript:check",
"lint": "yarn lint:check",
"lint:typescript:fix": "eslint --fix .",
......@@ -95,7 +95,6 @@
"prettier": "^2.3.1",
"random-bytes-seed": "^1.0.3",
"rlp": "^2.2.6",
"solhint": "^3.3.6",
"solidity-coverage": "^0.7.16",
"ts-generator": "0.0.8",
"ts-node": "^10.0.0",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment