-
Notifications
You must be signed in to change notification settings - Fork 706
Expand file tree
/
Copy pathReturnsTwoToken.sol
More file actions
61 lines (44 loc) · 1.89 KB
/
ReturnsTwoToken.sol
File metadata and controls
61 lines (44 loc) · 1.89 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
// SPDX-License-Identifier: AGPL-3.0-only
pragma solidity >=0.8.0;
contract ReturnsTwoToken {
/*///////////////////////////////////////////////////////////////
EVENTS
//////////////////////////////////////////////////////////////*/
event Transfer(address indexed from, address indexed to, uint256 amount);
event Approval(address indexed owner, address indexed spender, uint256 amount);
/*///////////////////////////////////////////////////////////////
METADATA STORAGE
//////////////////////////////////////////////////////////////*/
string public constant name = "ReturnsTwoToken";
string public constant symbol = "RTT";
uint8 public constant decimals = 18;
/*///////////////////////////////////////////////////////////////
ERC20 STORAGE
//////////////////////////////////////////////////////////////*/
uint256 public totalSupply;
mapping(address => uint256) public balanceOf;
mapping(address => mapping(address => uint256)) public allowance;
/*///////////////////////////////////////////////////////////////
CONSTRUCTOR
//////////////////////////////////////////////////////////////*/
constructor() {
totalSupply = type(uint256).max;
balanceOf[msg.sender] = type(uint256).max;
}
/*///////////////////////////////////////////////////////////////
ERC20 LOGIC
//////////////////////////////////////////////////////////////*/
function approve(address, uint256) public virtual returns (uint256) {
return 2;
}
function transfer(address, uint256) public virtual returns (uint256) {
return 2;
}
function transferFrom(
address,
address,
uint256
) public virtual returns (uint256) {
return 2;
}
}