Skip to content

Commit 28a3a64

Browse files
authored
Update Amis.sol
1 parent 08a5661 commit 28a3a64

File tree

1 file changed

+1
-64
lines changed

1 file changed

+1
-64
lines changed

contracts/Amis.sol

+1-64
Original file line numberDiff line numberDiff line change
@@ -1,70 +1,7 @@
1-
// # https://remix.ethereum.org/#version=soljson-v0.5.24+commit.e67f0147.js&optimize=true&gist=7f2a15679aee59fba912aa929f70df1d
1+
// # https://remix.ethereum.org/#version=soljson-v0.5.24+commit.e67f0147.js&optimize=true&gist=6ba2843f228efec36624338245bd09dd
22
//
33
pragma solidity ^0.5.24;
44

5-
contract ERC223 {
6-
uint public totalSupply;
7-
function balanceOf(address who) public view returns (uint);
8-
9-
function name() public view returns (string _name);
10-
function symbol() public view returns (string _symbol);
11-
function decimals() public view returns (uint8 _decimals);
12-
function totalSupply() public view returns (uint256 _supply);
13-
14-
function transfer(address to, uint value) public returns (bool ok);
15-
function transfer(address to, uint value, bytes data) public returns (bool ok);
16-
function transfer(address to, uint value, bytes data, string custom_fallback) public returns (bool ok);
17-
18-
event Transfer(address indexed from, address indexed to, uint value, bytes indexed data);
19-
20-
}
21-
22-
23-
library SafeMath {
24-
25-
function add(uint256 a, uint256 b) internal pure returns (uint256) {
26-
uint256 c = a + b;
27-
require(c >= a, "SafeMath: addition overflow");
28-
29-
return c;
30-
}
31-
32-
function sub(uint256 a, uint256 b) internal pure returns (uint256) {
33-
require(b <= a, "SafeMath: subtraction overflow");
34-
uint256 c = a - b;
35-
36-
return c;
37-
}
38-
39-
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
40-
// Gas optimization: this is cheaper than requiring 'a' not being zero, but the
41-
// benefit is lost if 'b' is also tested.
42-
// See: https://github.com/OpenZeppelin/openzeppelin-solidity/pull/522
43-
if (a == 0) {
44-
return 0;
45-
}
46-
47-
uint256 c = a * b;
48-
require(c / a == b, "SafeMath: multiplication overflow");
49-
50-
return c;
51-
}
52-
53-
function div(uint256 a, uint256 b) internal pure returns (uint256) {
54-
// Solidity only automatically asserts when dividing by 0
55-
require(b > 0, "SafeMath: division by zero");
56-
uint256 c = a / b;
57-
// assert(a == b * c + a % b); // There is no case in which this doesn't hold
58-
59-
return c;
60-
}
61-
62-
function mod(uint256 a, uint256 b) internal pure returns (uint256) {
63-
require(b != 0, "SafeMath: modulo by zero");
64-
return a % b;
65-
}
66-
}
67-
685
// change contract name to your contract's name
696
// i.e. "contract AMIS is ERC223Token"
707
contract Amis is ERC223Token {

0 commit comments

Comments
 (0)