diff --git a/.gas-snapshot b/.gas-snapshot new file mode 100644 index 0000000..e69de29 diff --git a/contracts/SNTPlaceHolder.sol b/contracts/SNTPlaceHolder.sol index 6df3798..404f8cd 100644 --- a/contracts/SNTPlaceHolder.sol +++ b/contracts/SNTPlaceHolder.sol @@ -3,7 +3,6 @@ pragma solidity ^0.8.18; import { TokenController } from "@vacp2p/minime/contracts/TokenController.sol"; import { MiniMeToken } from "@vacp2p/minime/contracts/MiniMeToken.sol"; -import "./SafeMath.sol"; import "./Owned.sol"; /* @@ -31,8 +30,6 @@ import "./Owned.sol"; /// logic for transferring control of the token to the network when the offering /// asks it to do so. contract SNTPlaceHolder is TokenController, Owned { - using SafeMath for uint256; - MiniMeToken public snt; constructor(address _owner, address payable _snt) { diff --git a/contracts/SafeMath.sol b/contracts/SafeMath.sol deleted file mode 100644 index 2e42ca0..0000000 --- a/contracts/SafeMath.sol +++ /dev/null @@ -1,47 +0,0 @@ -// SPDX-License-Identifier: GPL-3.0 -pragma solidity ^0.8.18; - -/** - * Math operations with safety checks - */ -library SafeMath { - function mul(uint256 a, uint256 b) internal pure returns (uint256) { - uint256 c = a * b; - assert(a == 0 || c / a == b); - return c; - } - - function div(uint256 a, uint256 b) internal pure returns (uint256) { - // assert(b > 0); // Solidity automatically throws when dividing by 0 - uint256 c = a / b; - // assert(a == b * c + a % b); // There is no case in which this doesn't hold - return c; - } - - function sub(uint256 a, uint256 b) internal pure returns (uint256) { - assert(b <= a); - return a - b; - } - - function add(uint256 a, uint256 b) internal pure returns (uint256) { - uint256 c = a + b; - assert(c >= a); - return c; - } - - function max64(uint64 a, uint64 b) internal pure returns (uint64) { - return a >= b ? a : b; - } - - function min64(uint64 a, uint64 b) internal pure returns (uint64) { - return a < b ? a : b; - } - - function max256(uint256 a, uint256 b) internal pure returns (uint256) { - return a >= b ? a : b; - } - - function min256(uint256 a, uint256 b) internal pure returns (uint256) { - return a < b ? a : b; - } -}