@1inch/solidity-utils 2.2.20 → 2.2.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE.md CHANGED
@@ -1,4 +1,4 @@
1
- Copyright (c) 2019-2021 1inch
1
+ Copyright (c) 2019-2023 1inch
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
4
4
 
@@ -1,7 +1,6 @@
1
1
  // SPDX-License-Identifier: MIT
2
2
 
3
3
  pragma solidity ^0.8.0;
4
- pragma abicoder v1;
5
4
 
6
5
  abstract contract EthReceiver {
7
6
  error EthDepositRejected();
@@ -1,7 +1,6 @@
1
1
  // SPDX-License-Identifier: MIT
2
2
 
3
3
  pragma solidity ^0.8.0;
4
- pragma abicoder v1;
5
4
 
6
5
  contract GasChecker {
7
6
  error GasCostDiffers(uint256 expected, uint256 actual);
@@ -12,6 +11,8 @@ contract GasChecker {
12
11
  unchecked {
13
12
  gas -= gasleft();
14
13
  }
15
- if (expected > 0 && gas != expected) revert GasCostDiffers(expected, gas);
14
+ if (expected > 0 && gas != expected) {
15
+ revert GasCostDiffers(expected, gas);
16
+ }
16
17
  }
17
18
  }
@@ -1,7 +1,6 @@
1
1
  // SPDX-License-Identifier: MIT
2
2
 
3
3
  pragma solidity ^0.8.0;
4
- pragma abicoder v1;
5
4
 
6
5
  import "./EthReceiver.sol";
7
6
 
@@ -1,7 +1,6 @@
1
1
  // SPDX-License-Identifier: MIT
2
2
 
3
3
  pragma solidity ^0.8.0;
4
- pragma abicoder v1;
5
4
 
6
5
  interface IDaiLikePermit {
7
6
  function permit(
@@ -1,7 +1,6 @@
1
1
  // SPDX-License-Identifier: MIT
2
2
 
3
3
  pragma solidity ^0.8.0;
4
- pragma abicoder v1;
5
4
 
6
5
  interface IERC20MetadataUppercase {
7
6
  function NAME() external view returns (string memory); // solhint-disable-line func-name-mixedcase
@@ -1,7 +1,6 @@
1
1
  // SPDX-License-Identifier: MIT
2
2
 
3
3
  pragma solidity ^0.8.0;
4
- pragma abicoder v1;
5
4
 
6
5
  import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
7
6
 
@@ -1,7 +1,6 @@
1
1
  // SPDX-License-Identifier: MIT
2
2
 
3
3
  pragma solidity ^0.8.0;
4
- pragma abicoder v1;
5
4
 
6
5
  /// @title Library that implements address array on mapping, stores array length at 0 index.
7
6
  library AddressArray {
@@ -1,7 +1,6 @@
1
1
  // SPDX-License-Identifier: MIT
2
2
 
3
3
  pragma solidity ^0.8.0;
4
- pragma abicoder v1;
5
4
 
6
5
  type Address is uint256;
7
6
 
@@ -1,7 +1,6 @@
1
1
  // SPDX-License-Identifier: MIT
2
2
 
3
3
  pragma solidity ^0.8.0;
4
- pragma abicoder v1;
5
4
 
6
5
  import "./AddressArray.sol";
7
6
 
@@ -1,7 +1,6 @@
1
1
  // SPDX-License-Identifier: MIT
2
2
 
3
3
  pragma solidity ^0.8.0;
4
- pragma abicoder v1;
5
4
 
6
5
  import "@openzeppelin/contracts/interfaces/IERC1271.sol";
7
6
 
@@ -1,7 +1,6 @@
1
1
  // SPDX-License-Identifier: MIT
2
2
 
3
3
  pragma solidity ^0.8.0;
4
- pragma abicoder v1;
5
4
 
6
5
  /// @title Revert reason forwarder.
7
6
  library RevertReasonForwarder {
@@ -1,7 +1,6 @@
1
1
  // SPDX-License-Identifier: MIT
2
2
 
3
3
  pragma solidity ^0.8.0;
4
- pragma abicoder v1;
5
4
 
6
5
  import "./StringUtil.sol";
7
6
 
@@ -1,7 +1,6 @@
1
1
  // SPDX-License-Identifier: MIT
2
2
 
3
3
  pragma solidity ^0.8.0;
4
- pragma abicoder v1;
5
4
 
6
5
  import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
7
6
  import "@openzeppelin/contracts/token/ERC20/extensions/draft-IERC20Permit.sol";
@@ -1,7 +1,6 @@
1
1
  // SPDX-License-Identifier: MIT
2
2
 
3
3
  pragma solidity ^0.8.0;
4
- pragma abicoder v1;
5
4
 
6
5
  /// @title Library with gas-efficient string operations
7
6
  library StringUtil {
@@ -1,7 +1,6 @@
1
1
  // SPDX-License-Identifier: MIT
2
2
 
3
3
  pragma solidity ^0.8.0;
4
- pragma abicoder v1;
5
4
 
6
5
  import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
7
6
  import "@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.sol";
@@ -1,7 +1,6 @@
1
1
  // SPDX-License-Identifier: MIT
2
2
 
3
3
  pragma solidity ^0.8.0;
4
- pragma abicoder v1;
5
4
 
6
5
  import "@openzeppelin/contracts/access/Ownable.sol";
7
6
  import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@1inch/solidity-utils",
3
- "version": "2.2.20",
3
+ "version": "2.2.21",
4
4
  "main": "dist/src/index.js",
5
5
  "types": "dist/src/index.d.ts",
6
6
  "repository": {
@@ -12,7 +12,7 @@
12
12
  "clean": "rimraf artifacts cache coverage contracts/hardhat-dependency-compiler dist typechain-types",
13
13
  "build": "yarn typechain && cti src -b && tsc -p tsconfig.publish.json",
14
14
  "prepack": "yarn clean && yarn build",
15
- "coverage": "hardhat coverage",
15
+ "coverage": "skip_on_coverage=true hardhat coverage",
16
16
  "format": "yarn format-ts && yarn format-sol",
17
17
  "format-ts": "prettier '**/*.ts' --write",
18
18
  "format-sol": "prettier '**/*.sol' --write",
@@ -34,8 +34,7 @@
34
34
  "@openzeppelin/contracts": "4.7.3",
35
35
  "@uniswap/permit2-sdk": "^1.2.0",
36
36
  "ethereumjs-util": "7.1.5",
37
- "ethers": "5.7.1",
38
- "hardhat": "2.11.2"
37
+ "ethers": "5.7.1"
39
38
  },
40
39
  "devDependencies": {
41
40
  "@nomicfoundation/hardhat-chai-matchers": "1.0.3",
@@ -61,6 +60,7 @@
61
60
  "eslint-plugin-promise": "6.0.1",
62
61
  "eslint-plugin-standard": "5.0.0",
63
62
  "ethereumjs-wallet": "1.0.2",
63
+ "hardhat": "2.12.8-viair.0",
64
64
  "hardhat-gas-reporter": "1.0.9",
65
65
  "hardhat-tracer": "2.1.2",
66
66
  "prettier": "2.7.1",