From c41c54b4fb38f20d174db822f46a5b2e5c82de54 Mon Sep 17 00:00:00 2001 From: sujithsomraaj Date: Mon, 16 Oct 2023 18:30:10 -0400 Subject: [PATCH] feat: migrate to solidity v0.8.21 --- .gitmodules | 6 +- foundry.toml | 4 +- lib/openzeppelin-contracts | 2 +- src/ERC1155A.sol | 2 +- src/interfaces/IERC1155A.sol | 16 ++- src/interfaces/ITransmuter.sol | 9 +- src/test/ERC1155.t.sol | 181 +++++++++++++++++++++++------- src/test/ERC1155_A.t.sol | 4 +- src/test/Transmuter.t.sol | 10 +- src/test/mocks/MockERC1155A.sol | 6 +- src/test/mocks/MockTransmuter.sol | 15 ++- src/transmuter/Transmuter.sol | 27 +++-- src/transmuter/sERC20.sol | 4 +- 13 files changed, 208 insertions(+), 78 deletions(-) diff --git a/.gitmodules b/.gitmodules index 506403b..c81fdbd 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,9 +1,9 @@ [submodule "lib/forge-std"] path = lib/forge-std url = https://github.com/foundry-rs/forge-std -[submodule "lib/openzeppelin-contracts"] - path = lib/openzeppelin-contracts - url = https://github.com/OpenZeppelin/openzeppelin-contracts [submodule "lib/solmate"] path = lib/solmate url = https://github.com/transmissions11/solmate +[submodule "lib/openzeppelin-contracts"] + path = lib/openzeppelin-contracts + url = https://github.com/OpenZeppelin/openzeppelin-contracts diff --git a/foundry.toml b/foundry.toml index e801f40..9b108e7 100644 --- a/foundry.toml +++ b/foundry.toml @@ -1,6 +1,6 @@ [profile.default] libs = ['lib'] -solc_version = "0.8.19" +solc_version = "0.8.21" optimizer = true optimizer_runs = 200 @@ -14,4 +14,4 @@ multiline_func_header = "all" number_underscore = "thousands" quote_style = "double" tab_width = 4 -wrap_comments = true \ No newline at end of file +wrap_comments = true diff --git a/lib/openzeppelin-contracts b/lib/openzeppelin-contracts index fd81a96..932fddf 160000 --- a/lib/openzeppelin-contracts +++ b/lib/openzeppelin-contracts @@ -1 +1 @@ -Subproject commit fd81a96f01cc42ef1c9a5399364968d0e07e9e90 +Subproject commit 932fddf69a699a9a80fd2396fd1a2ab91cdda123 diff --git a/src/ERC1155A.sol b/src/ERC1155A.sol index aa59348..3df6258 100644 --- a/src/ERC1155A.sol +++ b/src/ERC1155A.sol @@ -1,5 +1,5 @@ /// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.19; +pragma solidity ^0.8.21; import { IERC1155A } from "./interfaces/IERC1155A.sol"; import { Strings } from "openzeppelin-contracts/contracts/utils/Strings.sol"; diff --git a/src/interfaces/IERC1155A.sol b/src/interfaces/IERC1155A.sol index 838682e..2e8761f 100644 --- a/src/interfaces/IERC1155A.sol +++ b/src/interfaces/IERC1155A.sol @@ -1,7 +1,7 @@ /// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.19; +pragma solidity ^0.8.21; -import {IERC1155} from "openzeppelin-contracts/contracts/token/ERC1155/IERC1155.sol"; +import { IERC1155 } from "openzeppelin-contracts/contracts/token/ERC1155/IERC1155.sol"; interface IERC1155A is IERC1155 { /*////////////////////////////////////////////////////////////// @@ -41,13 +41,21 @@ interface IERC1155A is IERC1155 { /// @notice Public function for increasing multiple id approval amount at once /// @dev extension of single id increase allowance - function increaseAllowanceForMany(address spender, uint256[] memory ids, uint256[] memory addedValues) + function increaseAllowanceForMany( + address spender, + uint256[] memory ids, + uint256[] memory addedValues + ) external returns (bool); /// @notice Public function for decreasing multiple id approval amount at once /// @dev extension of single id decrease allowance - function decreaseAllowanceForMany(address spender, uint256[] memory ids, uint256[] memory subtractedValues) + function decreaseAllowanceForMany( + address spender, + uint256[] memory ids, + uint256[] memory subtractedValues + ) external returns (bool); diff --git a/src/interfaces/ITransmuter.sol b/src/interfaces/ITransmuter.sol index 1057e93..230acdb 100644 --- a/src/interfaces/ITransmuter.sol +++ b/src/interfaces/ITransmuter.sol @@ -1,5 +1,5 @@ /// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.19; +pragma solidity ^0.8.21; interface ITransmuter { /// @notice id given here needs to be the same as id on Source! @@ -9,7 +9,12 @@ interface ITransmuter { /// @param name name of the ERC20 to create /// @param symbol symbol of the ERC20 to create /// @param decimals decimals of the ERC20 to create - function registerTransmuter(uint256 id, string memory name, string memory symbol, uint8 decimals) + function registerTransmuter( + uint256 id, + string memory name, + string memory symbol, + uint8 decimals + ) external returns (address); diff --git a/src/test/ERC1155.t.sol b/src/test/ERC1155.t.sol index 356b323..518b52e 100644 --- a/src/test/ERC1155.t.sol +++ b/src/test/ERC1155.t.sol @@ -1,10 +1,10 @@ /// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.19; +pragma solidity ^0.8.21; -import {DSTestPlus} from "solmate/test/utils/DSTestPlus.sol"; -import {DSInvariantTest} from "solmate/test/utils/DSInvariantTest.sol"; -import {ERC1155TokenReceiver} from "solmate/tokens/ERC1155.sol"; -import {MockERC1155A} from "./mocks/MockERC1155A.sol"; +import { DSTestPlus } from "solmate/test/utils/DSTestPlus.sol"; +import { DSInvariantTest } from "solmate/test/utils/DSInvariantTest.sol"; +import { ERC1155TokenReceiver } from "solmate/tokens/ERC1155.sol"; +import { MockERC1155A } from "./mocks/MockERC1155A.sol"; /** * @title ERC1155 Test Suite from Solmate re-adapted for ERC1155A @@ -20,7 +20,13 @@ contract ERC1155Recipient is ERC1155TokenReceiver { uint256 public amount; bytes public mintData; - function onERC1155Received(address _operator, address _from, uint256 _id, uint256 _amount, bytes calldata _data) + function onERC1155Received( + address _operator, + address _from, + uint256 _id, + uint256 _amount, + bytes calldata _data + ) public override returns (bytes4) @@ -54,7 +60,11 @@ contract ERC1155Recipient is ERC1155TokenReceiver { uint256[] calldata _ids, uint256[] calldata _amounts, bytes calldata _data - ) external override returns (bytes4) { + ) + external + override + returns (bytes4) + { batchOperator = _operator; batchFrom = _from; _batchIds = _ids; @@ -66,7 +76,13 @@ contract ERC1155Recipient is ERC1155TokenReceiver { } contract RevertingERC1155Recipient is ERC1155TokenReceiver { - function onERC1155Received(address, address, uint256, uint256, bytes calldata) + function onERC1155Received( + address, + address, + uint256, + uint256, + bytes calldata + ) public pure override @@ -75,7 +91,13 @@ contract RevertingERC1155Recipient is ERC1155TokenReceiver { revert(string(abi.encodePacked(ERC1155TokenReceiver.onERC1155Received.selector))); } - function onERC1155BatchReceived(address, address, uint256[] calldata, uint256[] calldata, bytes calldata) + function onERC1155BatchReceived( + address, + address, + uint256[] calldata, + uint256[] calldata, + bytes calldata + ) external pure override @@ -86,7 +108,13 @@ contract RevertingERC1155Recipient is ERC1155TokenReceiver { } contract WrongReturnDataERC1155Recipient is ERC1155TokenReceiver { - function onERC1155Received(address, address, uint256, uint256, bytes calldata) + function onERC1155Received( + address, + address, + uint256, + uint256, + bytes calldata + ) public pure override @@ -95,7 +123,13 @@ contract WrongReturnDataERC1155Recipient is ERC1155TokenReceiver { return 0xCAFEBEEF; } - function onERC1155BatchReceived(address, address, uint256[] calldata, uint256[] calldata, bytes calldata) + function onERC1155BatchReceived( + address, + address, + uint256[] calldata, + uint256[] calldata, + bytes calldata + ) external pure override @@ -105,7 +139,7 @@ contract WrongReturnDataERC1155Recipient is ERC1155TokenReceiver { } } -contract NonERC1155Recipient {} +contract NonERC1155Recipient { } contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { MockERC1155A token; @@ -859,7 +893,12 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { assertBytesEq(to.mintData(), mintData); } - function testBatchMintToEOA(address to, uint256[] memory ids, uint256[] memory amounts, bytes memory mintData) + function testBatchMintToEOA( + address to, + uint256[] memory ids, + uint256[] memory amounts, + bytes memory mintData + ) public { if (to == address(0)) to = address(0xBEEF); @@ -893,7 +932,11 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { } } - function testBatchMintToERC1155Recipient(uint256[] memory ids, uint256[] memory amounts, bytes memory mintData) + function testBatchMintToERC1155Recipient( + uint256[] memory ids, + uint256[] memory amounts, + bytes memory mintData + ) public { ERC1155Recipient to = new ERC1155Recipient(); @@ -953,7 +996,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256[] memory mintAmounts, uint256[] memory burnAmounts, bytes memory mintData - ) public { + ) + public + { if (to == address(0)) to = address(0xBEEF); if (uint256(uint160(to)) <= 18 || to.code.length > 0) return; @@ -1004,7 +1049,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256 transferAmount, address to, bytes memory transferData - ) public { + ) + public + { if (to == address(0)) to = address(0xBEEF); if (uint256(uint160(to)) <= 18 || to.code.length > 0) return; @@ -1034,7 +1081,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { bytes memory mintData, uint256 transferAmount, bytes memory transferData - ) public { + ) + public + { ERC1155Recipient to = new ERC1155Recipient(); address from = address(0xABCD); @@ -1064,7 +1113,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256 transferAmount, address to, bytes memory transferData - ) public { + ) + public + { if (to == address(0)) to = address(0xBEEF); if (uint256(uint160(to)) <= 18 || to.code.length > 0) return; @@ -1086,7 +1137,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256[] memory transferAmounts, bytes memory mintData, bytes memory transferData - ) public { + ) + public + { if (to == address(0)) to = address(0xBEEF); if (uint256(uint160(to)) <= 18 || to.code.length > 0) return; @@ -1136,7 +1189,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256[] memory transferAmounts, bytes memory mintData, bytes memory transferData - ) public { + ) + public + { address from = address(0xABCD); ERC1155Recipient to = new ERC1155Recipient(); @@ -1190,7 +1245,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256[] memory ids, uint256[] memory amounts, bytes memory mintData - ) public { + ) + public + { uint256 minLength = min3(tos.length, ids.length, amounts.length); address[] memory normalizedTos = new address[](minLength); @@ -1231,7 +1288,11 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { token.mint(address(new RevertingERC1155Recipient()), id, mintAmount, mintData); } - function testFailMintToWrongReturnDataERC155Recipient(uint256 id, uint256 mintAmount, bytes memory mintData) + function testFailMintToWrongReturnDataERC155Recipient( + uint256 id, + uint256 mintAmount, + bytes memory mintData + ) public { token.mint(address(new RevertingERC1155Recipient()), id, mintAmount, mintData); @@ -1243,7 +1304,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256 mintAmount, uint256 burnAmount, bytes memory mintData - ) public { + ) + public + { burnAmount = bound(burnAmount, mintAmount + 1, type(uint256).max); token.mint(to, id, mintAmount, mintData); @@ -1257,7 +1320,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256 transferAmount, bytes memory mintData, bytes memory transferData - ) public { + ) + public + { address from = address(0xABCD); transferAmount = bound(transferAmount, mintAmount + 1, type(uint256).max); @@ -1277,7 +1342,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256 transferAmount, bytes memory mintData, bytes memory transferData - ) public { + ) + public + { transferAmount = bound(transferAmount, mintAmount + 1, type(uint256).max); token.mint(address(this), id, mintAmount, mintData); @@ -1290,7 +1357,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256 transferAmount, bytes memory mintData, bytes memory transferData - ) public { + ) + public + { transferAmount = bound(transferAmount, 0, mintAmount); token.mint(address(this), id, mintAmount, mintData); @@ -1303,7 +1372,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256 transferAmount, bytes memory mintData, bytes memory transferData - ) public { + ) + public + { transferAmount = bound(transferAmount, 0, mintAmount); token.mint(address(this), id, mintAmount, mintData); @@ -1316,7 +1387,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256 transferAmount, bytes memory mintData, bytes memory transferData - ) public { + ) + public + { transferAmount = bound(transferAmount, 0, mintAmount); token.mint(address(this), id, mintAmount, mintData); @@ -1331,7 +1404,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256 transferAmount, bytes memory mintData, bytes memory transferData - ) public { + ) + public + { transferAmount = bound(transferAmount, 0, mintAmount); token.mint(address(this), id, mintAmount, mintData); @@ -1347,7 +1422,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256[] memory transferAmounts, bytes memory mintData, bytes memory transferData - ) public { + ) + public + { address from = address(0xABCD); uint256 minLength = min3(ids.length, mintAmounts.length, transferAmounts.length); @@ -1387,7 +1464,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256[] memory transferAmounts, bytes memory mintData, bytes memory transferData - ) public { + ) + public + { address from = address(0xABCD); uint256 minLength = min3(ids.length, mintAmounts.length, transferAmounts.length); @@ -1425,7 +1504,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256[] memory transferAmounts, bytes memory mintData, bytes memory transferData - ) public { + ) + public + { address from = address(0xABCD); uint256 minLength = min3(ids.length, mintAmounts.length, transferAmounts.length); @@ -1465,7 +1546,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256[] memory transferAmounts, bytes memory mintData, bytes memory transferData - ) public { + ) + public + { address from = address(0xABCD); uint256 minLength = min3(ids.length, mintAmounts.length, transferAmounts.length); @@ -1505,7 +1588,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256[] memory transferAmounts, bytes memory mintData, bytes memory transferData - ) public { + ) + public + { address from = address(0xABCD); uint256 minLength = min3(ids.length, mintAmounts.length, transferAmounts.length); @@ -1546,7 +1631,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256[] memory transferAmounts, bytes memory mintData, bytes memory transferData - ) public { + ) + public + { address from = address(0xABCD); if (ids.length == transferAmounts.length) revert(); @@ -1585,7 +1672,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256[] memory ids, uint256[] memory amounts, bytes memory mintData - ) public { + ) + public + { NonERC1155Recipient to = new NonERC1155Recipient(); uint256 minLength = min2(ids.length, amounts.length); @@ -1613,7 +1702,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256[] memory ids, uint256[] memory amounts, bytes memory mintData - ) public { + ) + public + { RevertingERC1155Recipient to = new RevertingERC1155Recipient(); uint256 minLength = min2(ids.length, amounts.length); @@ -1641,7 +1732,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256[] memory ids, uint256[] memory amounts, bytes memory mintData - ) public { + ) + public + { WrongReturnDataERC1155Recipient to = new WrongReturnDataERC1155Recipient(); uint256 minLength = min2(ids.length, amounts.length); @@ -1670,7 +1763,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256[] memory ids, uint256[] memory amounts, bytes memory mintData - ) public { + ) + public + { if (ids.length == amounts.length) revert(); token.batchMint(address(to), ids, amounts, mintData); @@ -1682,7 +1777,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256[] memory mintAmounts, uint256[] memory burnAmounts, bytes memory mintData - ) public { + ) + public + { uint256 minLength = min3(ids.length, mintAmounts.length, burnAmounts.length); if (minLength == 0) revert(); @@ -1714,7 +1811,9 @@ contract ERC1155Test is DSTestPlus, ERC1155TokenReceiver { uint256[] memory mintAmounts, uint256[] memory burnAmounts, bytes memory mintData - ) public { + ) + public + { if (ids.length == burnAmounts.length) revert(); token.batchMint(to, ids, mintAmounts, mintData); diff --git a/src/test/ERC1155_A.t.sol b/src/test/ERC1155_A.t.sol index 18a39a4..2ec7591 100644 --- a/src/test/ERC1155_A.t.sol +++ b/src/test/ERC1155_A.t.sol @@ -1,8 +1,8 @@ /// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.19; +pragma solidity ^0.8.21; import "forge-std/Test.sol"; -import {MockERC1155A} from "./mocks/MockERC1155A.sol"; +import { MockERC1155A } from "./mocks/MockERC1155A.sol"; contract ERC1155ATest is Test { MockERC1155A public SuperShares; diff --git a/src/test/Transmuter.t.sol b/src/test/Transmuter.t.sol index 7a793cf..7054620 100644 --- a/src/test/Transmuter.t.sol +++ b/src/test/Transmuter.t.sol @@ -1,11 +1,11 @@ /// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.19; +pragma solidity ^0.8.21; import "forge-std/Test.sol"; -import {MockTransmuter} from "./mocks/MockTransmuter.sol"; -import {MockERC1155A} from "./mocks/MockERC1155A.sol"; -import {ERC20} from "solmate/tokens/ERC20.sol"; -import {sERC20} from "../transmuter/sERC20.sol"; +import { MockTransmuter } from "./mocks/MockTransmuter.sol"; +import { MockERC1155A } from "./mocks/MockERC1155A.sol"; +import { ERC20 } from "solmate/tokens/ERC20.sol"; +import { sERC20 } from "../transmuter/sERC20.sol"; contract TransmuterTest is Test { uint256 public constant THOUSAND_E18 = 1000 ether; diff --git a/src/test/mocks/MockERC1155A.sol b/src/test/mocks/MockERC1155A.sol index 7394bca..909106c 100644 --- a/src/test/mocks/MockERC1155A.sol +++ b/src/test/mocks/MockERC1155A.sol @@ -1,8 +1,8 @@ /// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.19; +pragma solidity ^0.8.21; -import {ERC1155A} from "../../ERC1155A.sol"; -import {Strings} from "openzeppelin-contracts/contracts/utils/Strings.sol"; +import { ERC1155A } from "../../ERC1155A.sol"; +import { Strings } from "openzeppelin-contracts/contracts/utils/Strings.sol"; /// @notice For test purpouses we open mint()/burn() functions of ERC1155A contract MockERC1155A is ERC1155A { diff --git a/src/test/mocks/MockTransmuter.sol b/src/test/mocks/MockTransmuter.sol index 264e0a4..559162b 100644 --- a/src/test/mocks/MockTransmuter.sol +++ b/src/test/mocks/MockTransmuter.sol @@ -1,9 +1,9 @@ /// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.19; +pragma solidity ^0.8.21; -import {IERC1155A} from "../../interfaces/IERC1155A.sol"; -import {Transmuter} from "../../transmuter/Transmuter.sol"; -import {sERC20} from "../../transmuter/sERC20.sol"; +import { IERC1155A } from "../../interfaces/IERC1155A.sol"; +import { Transmuter } from "../../transmuter/Transmuter.sol"; +import { sERC20 } from "../../transmuter/sERC20.sol"; /// @notice For test purpouses we open mint()/burn() functions of ERC1155s contract MockTransmuter is Transmuter { @@ -15,7 +15,12 @@ contract MockTransmuter is Transmuter { deployer = deployer_; } - function registerTransmuter(uint256 id, string memory name, string memory symbol, uint8 decimals) + function registerTransmuter( + uint256 id, + string memory name, + string memory symbol, + uint8 decimals + ) external override returns (address) diff --git a/src/transmuter/Transmuter.sol b/src/transmuter/Transmuter.sol index 77cb5c5..ff1bffe 100644 --- a/src/transmuter/Transmuter.sol +++ b/src/transmuter/Transmuter.sol @@ -1,9 +1,9 @@ /// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.19; +pragma solidity ^0.8.21; -import {IERC1155A} from "../interfaces/IERC1155A.sol"; -import {sERC20} from "./sERC20.sol"; -import {ITransmuter} from "../interfaces/ITransmuter.sol"; +import { IERC1155A } from "../interfaces/IERC1155A.sol"; +import { sERC20 } from "./sERC20.sol"; +import { ITransmuter } from "../interfaces/ITransmuter.sol"; /// @title Transmuter /// @author Zeropoint Labs. @@ -24,7 +24,12 @@ abstract contract Transmuter is ITransmuter { } /// @inheritdoc ITransmuter - function registerTransmuter(uint256 id, string memory name, string memory symbol, uint8 decimals) + function registerTransmuter( + uint256 id, + string memory name, + string memory symbol, + uint8 decimals + ) external virtual override @@ -101,7 +106,11 @@ abstract contract Transmuter is ITransmuter { uint256, /*id*/ uint256, /*value*/ bytes calldata /*data*/ - ) external pure returns (bytes4) { + ) + external + pure + returns (bytes4) + { return this.onERC1155Received.selector; } @@ -111,7 +120,11 @@ abstract contract Transmuter is ITransmuter { uint256[] calldata, /*ids*/ uint256[] calldata, /*values*/ bytes calldata /*data*/ - ) external pure returns (bytes4) { + ) + external + pure + returns (bytes4) + { return this.onERC1155BatchReceived.selector; } } diff --git a/src/transmuter/sERC20.sol b/src/transmuter/sERC20.sol index 903989c..ec4d0b2 100644 --- a/src/transmuter/sERC20.sol +++ b/src/transmuter/sERC20.sol @@ -1,7 +1,7 @@ /// SPDX-License-Identifier: Apache-2.0 -pragma solidity ^0.8.19; +pragma solidity ^0.8.21; -import {ERC20} from "solmate/tokens/ERC20.sol"; +import { ERC20 } from "solmate/tokens/ERC20.sol"; /// @title sERC20 /// @author Zeropoint Labs.