From 7985840af1f60f93fb43bbaedf6e26054fb2e7e0 Mon Sep 17 00:00:00 2001 From: pcaversaccio Date: Wed, 11 Mar 2026 12:20:22 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=94=81=20Update=20`prettier-plugin-solidi?= =?UTF-8?q?ty`=20to=20`2.3.0`?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: pcaversaccio --- README.md | 5 ++-- package.json | 4 ++-- pnpm-lock.yaml | 24 +++++++++---------- .../CreateX.deployCreate2Clone_2Args.t.sol | 15 ++++++------ .../CreateX.deployCreate2Clone_3Args.t.sol | 15 ++++++------ .../CreateX.deployCreate3AndInit_3Args.t.sol | 5 ++-- ...AndInit_4Args_CustomiseRefundAddress.t.sol | 5 ++-- ...oyCreate3AndInit_4Args_CustomiseSalt.t.sol | 5 ++-- .../CreateX.deployCreate3AndInit_5Args.t.sol | 5 ++-- .../CREATE3/CreateX.deployCreate3_1Arg.t.sol | 5 ++-- .../CREATE3/CreateX.deployCreate3_2Args.t.sol | 5 ++-- 11 files changed, 48 insertions(+), 45 deletions(-) diff --git a/README.md b/README.md index 85fd8d1d..1d0f95fd 100644 --- a/README.md +++ b/README.md @@ -761,9 +761,8 @@ function _guard(bytes32 salt) internal view returns (bytes32 guardedSalt) { } else { // For the non-pseudo-random cases, the salt value `salt` is hashed to prevent the safeguard mechanisms // from being bypassed. Otherwise, the salt value `salt` is not modified. - guardedSalt = (salt != _generateSalt()) - ? keccak256(abi.encode(salt)) - : salt; + guardedSalt = + (salt != _generateSalt()) ? keccak256(abi.encode(salt)) : salt; } } ``` diff --git a/package.json b/package.json index 5fa6aba2..3628f8ec 100644 --- a/package.json +++ b/package.json @@ -21,7 +21,7 @@ }, "author": "pcaversaccio (https://pcaversaccio.com), Matt Solomon (https://mattsolomon.dev)", "license": "AGPL-3.0-only", - "packageManager": "pnpm@10.32.0", + "packageManager": "pnpm@10.32.1", "scripts": { "clean": "hardhat clean && forge clean", "test": "forge test --out forge-artifacts", @@ -275,7 +275,7 @@ "hardhat-contract-sizer": "^2.10.1", "hardhat-gas-reporter": "^2.3.0", "prettier": "^3.8.1", - "prettier-plugin-solidity": "^2.2.1", + "prettier-plugin-solidity": "^2.3.0", "solhint": "^6.0.3", "ts-node": "^10.9.2", "typechain": "^8.3.2", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 4eed6622..769b59a7 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -51,8 +51,8 @@ importers: specifier: ^3.8.1 version: 3.8.1 prettier-plugin-solidity: - specifier: ^2.2.1 - version: 2.2.1(prettier@3.8.1) + specifier: ^2.3.0 + version: 2.3.0(prettier@3.8.1) solhint: specifier: ^6.0.3 version: 6.0.3(typescript@5.9.3) @@ -782,8 +782,8 @@ packages: peerDependencies: hardhat: ^2.26.0 - '@nomicfoundation/slang@1.3.1': - resolution: {integrity: sha512-gh0+JDjazmevEYCcwVgtuyfBJcV1209gIORZNRjUxbGzbQN0MOhQO9T0ptkzHKCf854gUy27SMxPbAyAu63fvQ==} + '@nomicfoundation/slang@1.3.4': + resolution: {integrity: sha512-ghzrPSYH1sZO65id6+Bq2Ood87HT54QP3RGC8EkmpcrJ6tT9Ky0RtaJfrzV5G4jpDsnNua6+YEDpzOMori04hQ==} '@nomicfoundation/solidity-analyzer-darwin-arm64@0.1.2': resolution: {integrity: sha512-JaqcWPDZENCvm++lFFGjrDd8mxtf+CtLd2MiXvMNTBD33dContTZ9TWETwNFwg7JTJT5Q9HEecH7FA+HTSsIUw==} @@ -3017,8 +3017,8 @@ packages: resolution: {integrity: sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==} engines: {node: '>= 0.8.0'} - prettier-plugin-solidity@2.2.1: - resolution: {integrity: sha512-LOHfxECJ/gHsY7qi4D7vanz8cVsCf6yFotBapJ5O0qaX0ZR1sGUzbWfMd4JeQYOItFl+wXW9IcjZOdfr6bmSvQ==} + prettier-plugin-solidity@2.3.0: + resolution: {integrity: sha512-3M/5w9gs7i2P0aHoyR/i61ZK7vb9AVYH/cS6YevNesS+qxvTZliGYBJNHgezaouqEAv81EEETJCmAs7/ghxNnA==} engines: {node: '>=20'} peerDependencies: prettier: '>=3.0.0' @@ -4408,7 +4408,7 @@ snapshots: transitivePeerDependencies: - supports-color - '@nomicfoundation/slang@1.3.1': + '@nomicfoundation/slang@1.3.4': dependencies: '@bytecodealliance/preview2-shim': 0.17.8 @@ -5604,7 +5604,7 @@ snapshots: eslint: 9.39.4(jiti@2.6.1) eslint-import-resolver-node: 0.3.9 eslint-import-resolver-typescript: 3.10.1(eslint-plugin-import@2.32.0(@typescript-eslint/parser@8.57.0(eslint@10.0.3(jiti@2.6.1))(typescript@5.9.3))(eslint@9.39.4(jiti@2.6.1)))(eslint@9.39.4(jiti@2.6.1)) - eslint-plugin-import: 2.32.0(@typescript-eslint/parser@8.57.0(eslint@10.0.3(jiti@2.6.1))(typescript@5.9.3))(eslint-import-resolver-typescript@3.10.1)(eslint@9.39.4(jiti@2.6.1)) + eslint-plugin-import: 2.32.0(@typescript-eslint/parser@8.57.0(eslint@10.0.3(jiti@2.6.1))(typescript@5.9.3))(eslint-import-resolver-typescript@3.10.1(eslint-plugin-import@2.32.0(@typescript-eslint/parser@8.57.0(eslint@10.0.3(jiti@2.6.1))(typescript@5.9.3))(eslint@9.39.4(jiti@2.6.1)))(eslint@9.39.4(jiti@2.6.1)))(eslint@9.39.4(jiti@2.6.1)) eslint-plugin-jsx-a11y: 6.10.2(eslint@9.39.4(jiti@2.6.1)) eslint-plugin-react: 7.37.5(eslint@9.39.4(jiti@2.6.1)) eslint-plugin-react-hooks: 7.0.1(eslint@9.39.4(jiti@2.6.1)) @@ -5641,7 +5641,7 @@ snapshots: tinyglobby: 0.2.15 unrs-resolver: 1.11.1 optionalDependencies: - eslint-plugin-import: 2.32.0(@typescript-eslint/parser@8.57.0(eslint@10.0.3(jiti@2.6.1))(typescript@5.9.3))(eslint-import-resolver-typescript@3.10.1)(eslint@9.39.4(jiti@2.6.1)) + eslint-plugin-import: 2.32.0(@typescript-eslint/parser@8.57.0(eslint@10.0.3(jiti@2.6.1))(typescript@5.9.3))(eslint-import-resolver-typescript@3.10.1(eslint-plugin-import@2.32.0(@typescript-eslint/parser@8.57.0(eslint@10.0.3(jiti@2.6.1))(typescript@5.9.3))(eslint@9.39.4(jiti@2.6.1)))(eslint@9.39.4(jiti@2.6.1)))(eslint@9.39.4(jiti@2.6.1)) transitivePeerDependencies: - supports-color @@ -5656,7 +5656,7 @@ snapshots: transitivePeerDependencies: - supports-color - eslint-plugin-import@2.32.0(@typescript-eslint/parser@8.57.0(eslint@10.0.3(jiti@2.6.1))(typescript@5.9.3))(eslint-import-resolver-typescript@3.10.1)(eslint@9.39.4(jiti@2.6.1)): + eslint-plugin-import@2.32.0(@typescript-eslint/parser@8.57.0(eslint@10.0.3(jiti@2.6.1))(typescript@5.9.3))(eslint-import-resolver-typescript@3.10.1(eslint-plugin-import@2.32.0(@typescript-eslint/parser@8.57.0(eslint@10.0.3(jiti@2.6.1))(typescript@5.9.3))(eslint@9.39.4(jiti@2.6.1)))(eslint@9.39.4(jiti@2.6.1)))(eslint@9.39.4(jiti@2.6.1)): dependencies: '@rtsao/scc': 1.1.0 array-includes: 3.1.9 @@ -6929,9 +6929,9 @@ snapshots: prelude-ls@1.2.1: {} - prettier-plugin-solidity@2.2.1(prettier@3.8.1): + prettier-plugin-solidity@2.3.0(prettier@3.8.1): dependencies: - '@nomicfoundation/slang': 1.3.1 + '@nomicfoundation/slang': 1.3.4 '@solidity-parser/parser': 0.20.2 prettier: 3.8.1 semver: 7.7.4 diff --git a/test/public/CREATE2/CreateX.deployCreate2Clone_2Args.t.sol b/test/public/CREATE2/CreateX.deployCreate2Clone_2Args.t.sol index 0fd23bef..10b90a5c 100644 --- a/test/public/CREATE2/CreateX.deployCreate2Clone_2Args.t.sol +++ b/test/public/CREATE2/CreateX.deployCreate2Clone_2Args.t.sol @@ -12,14 +12,13 @@ contract CreateX_DeployCreate2Clone_2Args_Public_Test is BaseTest { ImplementationContract internal implementationContract = new ImplementationContract(); address internal implementation = address(implementationContract); - bytes32 internal codeHash = - keccak256( - abi.encodePacked( - hex"36_3d_3d_37_3d_3d_3d_36_3d_73", - implementation, - hex"5a_f4_3d_82_80_3e_90_3d_91_60_2b_57_fd_5b_f3" - ) - ); + bytes32 internal codeHash = keccak256( + abi.encodePacked( + hex"36_3d_3d_37_3d_3d_3d_36_3d_73", + implementation, + hex"5a_f4_3d_82_80_3e_90_3d_91_60_2b_57_fd_5b_f3" + ) + ); /*´:°•.°+.*•´.*:˚.°*.˚•´.°:°•.°•.*•´.*:˚.°*.˚•´.°:°•.°+.*•´.*:*/ /* TESTS */ diff --git a/test/public/CREATE2/CreateX.deployCreate2Clone_3Args.t.sol b/test/public/CREATE2/CreateX.deployCreate2Clone_3Args.t.sol index 807c1fa6..e7379bc4 100644 --- a/test/public/CREATE2/CreateX.deployCreate2Clone_3Args.t.sol +++ b/test/public/CREATE2/CreateX.deployCreate2Clone_3Args.t.sol @@ -12,14 +12,13 @@ contract CreateX_DeployCreate2Clone_3Args_Public_Test is BaseTest { ImplementationContract internal implementationContract = new ImplementationContract(); address internal implementation = address(implementationContract); - bytes32 internal codeHash = - keccak256( - abi.encodePacked( - hex"36_3d_3d_37_3d_3d_3d_36_3d_73", - implementation, - hex"5a_f4_3d_82_80_3e_90_3d_91_60_2b_57_fd_5b_f3" - ) - ); + bytes32 internal codeHash = keccak256( + abi.encodePacked( + hex"36_3d_3d_37_3d_3d_3d_36_3d_73", + implementation, + hex"5a_f4_3d_82_80_3e_90_3d_91_60_2b_57_fd_5b_f3" + ) + ); // To avoid any stack-too-deep errors, we use an `internal` state variable for the snapshot ID. uint256 internal snapshotId; diff --git a/test/public/CREATE3/CreateX.deployCreate3AndInit_3Args.t.sol b/test/public/CREATE3/CreateX.deployCreate3AndInit_3Args.t.sol index ce2a7568..260c7b63 100644 --- a/test/public/CREATE3/CreateX.deployCreate3AndInit_3Args.t.sol +++ b/test/public/CREATE3/CreateX.deployCreate3AndInit_3Args.t.sol @@ -13,8 +13,9 @@ contract CreateX_DeployCreate3AndInit_3Args_Public_Test is BaseTest { /*.•°:°.´+˚.*°.˚:*.´•*.+°.•°:´*.´•*.•°.•°:°.´:•˚°.*°.˚:*.´+°.•*/ // The `keccak256`-hashed `CREATE3` proxy contract creation bytecode. - bytes32 internal proxyInitCodeHash = - keccak256(abi.encodePacked(hex"67_36_3d_3d_37_36_3d_34_f0_3d_52_60_08_60_18_f3")); + bytes32 internal proxyInitCodeHash = keccak256( + abi.encodePacked(hex"67_36_3d_3d_37_36_3d_34_f0_3d_52_60_08_60_18_f3") + ); // To avoid any stack-too-deep errors, we use `internal` state variables for the precomputed `CREATE3` address // and some further contract deployment addresses and variables. diff --git a/test/public/CREATE3/CreateX.deployCreate3AndInit_4Args_CustomiseRefundAddress.t.sol b/test/public/CREATE3/CreateX.deployCreate3AndInit_4Args_CustomiseRefundAddress.t.sol index 9713da52..d715ffb1 100644 --- a/test/public/CREATE3/CreateX.deployCreate3AndInit_4Args_CustomiseRefundAddress.t.sol +++ b/test/public/CREATE3/CreateX.deployCreate3AndInit_4Args_CustomiseRefundAddress.t.sol @@ -13,8 +13,9 @@ contract CreateX_DeployCreate3AndInit_4Args_CustomiseRefundAddress_Public_Test i /*.•°:°.´+˚.*°.˚:*.´•*.+°.•°:´*.´•*.•°.•°:°.´:•˚°.*°.˚:*.´+°.•*/ // The `keccak256`-hashed `CREATE3` proxy contract creation bytecode. - bytes32 internal proxyInitCodeHash = - keccak256(abi.encodePacked(hex"67_36_3d_3d_37_36_3d_34_f0_3d_52_60_08_60_18_f3")); + bytes32 internal proxyInitCodeHash = keccak256( + abi.encodePacked(hex"67_36_3d_3d_37_36_3d_34_f0_3d_52_60_08_60_18_f3") + ); // To avoid any stack-too-deep errors, we use `internal` state variables for the precomputed `CREATE3` address // and some further contract deployment addresses and variables. diff --git a/test/public/CREATE3/CreateX.deployCreate3AndInit_4Args_CustomiseSalt.t.sol b/test/public/CREATE3/CreateX.deployCreate3AndInit_4Args_CustomiseSalt.t.sol index ef5afa9f..227a7a32 100644 --- a/test/public/CREATE3/CreateX.deployCreate3AndInit_4Args_CustomiseSalt.t.sol +++ b/test/public/CREATE3/CreateX.deployCreate3AndInit_4Args_CustomiseSalt.t.sol @@ -13,8 +13,9 @@ contract CreateX_DeployCreate3AndInit_4Args_CustomiseSalt_Public_Test is BaseTes /*.•°:°.´+˚.*°.˚:*.´•*.+°.•°:´*.´•*.•°.•°:°.´:•˚°.*°.˚:*.´+°.•*/ // The `keccak256`-hashed `CREATE3` proxy contract creation bytecode. - bytes32 internal proxyInitCodeHash = - keccak256(abi.encodePacked(hex"67_36_3d_3d_37_36_3d_34_f0_3d_52_60_08_60_18_f3")); + bytes32 internal proxyInitCodeHash = keccak256( + abi.encodePacked(hex"67_36_3d_3d_37_36_3d_34_f0_3d_52_60_08_60_18_f3") + ); // To avoid any stack-too-deep errors, we use `internal` state variables for the precomputed `CREATE2` address // and some further contract deployment addresses and variables. diff --git a/test/public/CREATE3/CreateX.deployCreate3AndInit_5Args.t.sol b/test/public/CREATE3/CreateX.deployCreate3AndInit_5Args.t.sol index 5875b230..3caf9007 100644 --- a/test/public/CREATE3/CreateX.deployCreate3AndInit_5Args.t.sol +++ b/test/public/CREATE3/CreateX.deployCreate3AndInit_5Args.t.sol @@ -13,8 +13,9 @@ contract CreateX_DeployCreate3AndInit_5Args_Public_Test is BaseTest { /*.•°:°.´+˚.*°.˚:*.´•*.+°.•°:´*.´•*.•°.•°:°.´:•˚°.*°.˚:*.´+°.•*/ // The `keccak256`-hashed `CREATE3` proxy contract creation bytecode. - bytes32 internal proxyInitCodeHash = - keccak256(abi.encodePacked(hex"67_36_3d_3d_37_36_3d_34_f0_3d_52_60_08_60_18_f3")); + bytes32 internal proxyInitCodeHash = keccak256( + abi.encodePacked(hex"67_36_3d_3d_37_36_3d_34_f0_3d_52_60_08_60_18_f3") + ); // To avoid any stack-too-deep errors, we use `internal` state variables for the precomputed `CREATE2` address // and some further contract deployment addresses and variables. diff --git a/test/public/CREATE3/CreateX.deployCreate3_1Arg.t.sol b/test/public/CREATE3/CreateX.deployCreate3_1Arg.t.sol index 36c3cd7d..ac5b9cdb 100644 --- a/test/public/CREATE3/CreateX.deployCreate3_1Arg.t.sol +++ b/test/public/CREATE3/CreateX.deployCreate3_1Arg.t.sol @@ -13,8 +13,9 @@ contract CreateX_DeployCreate3_1Arg_Public_Test is BaseTest { /*.•°:°.´+˚.*°.˚:*.´•*.+°.•°:´*.´•*.•°.•°:°.´:•˚°.*°.˚:*.´+°.•*/ // The `keccak256`-hashed `CREATE3` proxy contract creation bytecode. - bytes32 internal proxyInitCodeHash = - keccak256(abi.encodePacked(hex"67_36_3d_3d_37_36_3d_34_f0_3d_52_60_08_60_18_f3")); + bytes32 internal proxyInitCodeHash = keccak256( + abi.encodePacked(hex"67_36_3d_3d_37_36_3d_34_f0_3d_52_60_08_60_18_f3") + ); // To avoid any stack-too-deep errors, we use `internal` state variables for the precomputed `CREATE3` address // and some further contract deployment addresses and variables. diff --git a/test/public/CREATE3/CreateX.deployCreate3_2Args.t.sol b/test/public/CREATE3/CreateX.deployCreate3_2Args.t.sol index 1bd441d0..d94e57d0 100644 --- a/test/public/CREATE3/CreateX.deployCreate3_2Args.t.sol +++ b/test/public/CREATE3/CreateX.deployCreate3_2Args.t.sol @@ -13,8 +13,9 @@ contract CreateX_DeployCreate3_2Args_Public_Test is BaseTest { /*.•°:°.´+˚.*°.˚:*.´•*.+°.•°:´*.´•*.•°.•°:°.´:•˚°.*°.˚:*.´+°.•*/ // The `keccak256`-hashed `CREATE3` proxy contract creation bytecode. - bytes32 internal proxyInitCodeHash = - keccak256(abi.encodePacked(hex"67_36_3d_3d_37_36_3d_34_f0_3d_52_60_08_60_18_f3")); + bytes32 internal proxyInitCodeHash = keccak256( + abi.encodePacked(hex"67_36_3d_3d_37_36_3d_34_f0_3d_52_60_08_60_18_f3") + ); // To avoid any stack-too-deep errors, we use `internal` state variables for the precomputed `CREATE3` address // and some further contract deployment addresses and variables.