6632 lines
277 KiB
JSON
6632 lines
277 KiB
JSON
{
|
|
"contractName": "Token",
|
|
"abi": [
|
|
{
|
|
"constant": true,
|
|
"inputs": [],
|
|
"name": "name",
|
|
"outputs": [
|
|
{
|
|
"name": "",
|
|
"type": "string"
|
|
}
|
|
],
|
|
"payable": false,
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"constant": true,
|
|
"inputs": [],
|
|
"name": "totalSupply",
|
|
"outputs": [
|
|
{
|
|
"name": "",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"payable": false,
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"constant": true,
|
|
"inputs": [],
|
|
"name": "decimals",
|
|
"outputs": [
|
|
{
|
|
"name": "",
|
|
"type": "uint8"
|
|
}
|
|
],
|
|
"payable": false,
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"constant": true,
|
|
"inputs": [],
|
|
"name": "symbol",
|
|
"outputs": [
|
|
{
|
|
"name": "",
|
|
"type": "string"
|
|
}
|
|
],
|
|
"payable": false,
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"payable": false,
|
|
"stateMutability": "nonpayable",
|
|
"type": "constructor"
|
|
},
|
|
{
|
|
"payable": true,
|
|
"stateMutability": "payable",
|
|
"type": "fallback"
|
|
},
|
|
{
|
|
"anonymous": false,
|
|
"inputs": [
|
|
{
|
|
"indexed": true,
|
|
"name": "_from",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"indexed": true,
|
|
"name": "_to",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"indexed": false,
|
|
"name": "_value",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "Transfer",
|
|
"type": "event"
|
|
},
|
|
{
|
|
"anonymous": false,
|
|
"inputs": [
|
|
{
|
|
"indexed": true,
|
|
"name": "_owner",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"indexed": true,
|
|
"name": "_spender",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"indexed": false,
|
|
"name": "_value",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "Approval",
|
|
"type": "event"
|
|
},
|
|
{
|
|
"constant": true,
|
|
"inputs": [
|
|
{
|
|
"name": "_owner",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "balanceOf",
|
|
"outputs": [
|
|
{
|
|
"name": "balance",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"payable": false,
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"inputs": [
|
|
{
|
|
"name": "_to",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"name": "_value",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "transfer",
|
|
"outputs": [
|
|
{
|
|
"name": "success",
|
|
"type": "bool"
|
|
}
|
|
],
|
|
"payable": false,
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"inputs": [
|
|
{
|
|
"name": "_from",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"name": "_to",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"name": "_value",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "transferFrom",
|
|
"outputs": [
|
|
{
|
|
"name": "success",
|
|
"type": "bool"
|
|
}
|
|
],
|
|
"payable": false,
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"inputs": [
|
|
{
|
|
"name": "_spender",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"name": "_value",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "approve",
|
|
"outputs": [
|
|
{
|
|
"name": "success",
|
|
"type": "bool"
|
|
}
|
|
],
|
|
"payable": false,
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"constant": true,
|
|
"inputs": [
|
|
{
|
|
"name": "_owner",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"name": "_spender",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "allowance",
|
|
"outputs": [
|
|
{
|
|
"name": "remaining",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"payable": false,
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
}
|
|
],
|
|
"bytecode": "0x608060405234801561001057600080fd5b506040805190810160405280600381526020017f544f4b00000000000000000000000000000000000000000000000000000000008152506000908051906020019061005c92919061019a565b506040805190810160405280600581526020017f546f6b656e000000000000000000000000000000000000000000000000000000815250600190805190602001906100a892919061019a565b506012600260006101000a81548160ff021916908360ff160217905550600260009054906101000a900460ff1660ff16600a0a633b9aca0002600381905550600354600460003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055503373ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef6003546040518082815260200191505060405180910390a361023f565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f106101db57805160ff1916838001178555610209565b82800160010185558215610209579182015b828111156102085782518255916020019190600101906101ed565b5b509050610216919061021a565b5090565b61023c91905b80821115610238576000816000905550600101610220565b5090565b90565b610c228061024e6000396000f300608060405260043610610099576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff16806306fdde031461009e578063095ea7b31461012e57806318160ddd1461019357806323b872dd146101be578063313ce5671461024357806370a082311461027457806395d89b41146102cb578063a9059cbb1461035b578063dd62ed3e146103c0575b600080fd5b3480156100aa57600080fd5b506100b3610437565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156100f35780820151818401526020810190506100d8565b50505050905090810190601f1680156101205780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561013a57600080fd5b50610179600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506104d5565b604051808215151515815260200191505060405180910390f35b34801561019f57600080fd5b506101a86105c7565b6040518082815260200191505060405180910390f35b3480156101ca57600080fd5b50610229600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b34801561024f57600080fd5b50610258610878565b604051808260ff1660ff16815260200191505060405180910390f35b34801561028057600080fd5b506102b5600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061088b565b6040518082815260200191505060405180910390f35b3480156102d757600080fd5b506102e06108d4565b6040518080602001828103825283818151815260200191508051906020019080838360005b83811015610320578082015181840152602081019050610305565b50505050905090810190601f16801561034d5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561036757600080fd5b506103a6600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610972565b604051808215151515815260200191505060405180910390f35b3480156103cc57600080fd5b50610421600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610b0d565b6040518082815260200191505060405180910390f35b60018054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156104cd5780601f106104a2576101008083540402835291602001916104cd565b820191906000526020600020905b8154815290600101906020018083116104b057829003601f168201915b505050505081565b600081600560003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925846040518082815260200191505060405180910390a36001905092915050565b60035481565b600061062182600460008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b9490919063ffffffff16565b600460008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506106f382600560008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b9490919063ffffffff16565b600560008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506107c582600460008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bb690919063ffffffff16565b600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef846040518082815260200191505060405180910390a3600190509392505050565b600260009054906101000a900460ff1681565b6000600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60008054600181600116156101000203166002900480601f01602080910402602001604051908101604052809291908181526020018280546001816001161561010002031660029004801561096a5780601f1061093f5761010080835404028352916020019161096a565b820191906000526020600020905b81548152906001019060200180831161094d57829003601f168201915b505050505081565b60006109c682600460003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b9490919063ffffffff16565b600460003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610a5b82600460008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bb690919063ffffffff16565b600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef846040518082815260200191505060405180910390a36001905092915050565b6000600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b6000610ba08383610bd8565b1515610bab57600080fd5b818303905092915050565b6000610bc28383610be6565b1515610bcd57600080fd5b818301905092915050565b600081831015905092915050565b60008282840110159050929150505600a165627a7a723058205a62e33bf5d7e96105d7623259a6ac0cd70a71d016410546f3c55a292e6e93db0029",
|
|
"deployedBytecode": "0x608060405260043610610099576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff16806306fdde031461009e578063095ea7b31461012e57806318160ddd1461019357806323b872dd146101be578063313ce5671461024357806370a082311461027457806395d89b41146102cb578063a9059cbb1461035b578063dd62ed3e146103c0575b600080fd5b3480156100aa57600080fd5b506100b3610437565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156100f35780820151818401526020810190506100d8565b50505050905090810190601f1680156101205780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561013a57600080fd5b50610179600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506104d5565b604051808215151515815260200191505060405180910390f35b34801561019f57600080fd5b506101a86105c7565b6040518082815260200191505060405180910390f35b3480156101ca57600080fd5b50610229600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b34801561024f57600080fd5b50610258610878565b604051808260ff1660ff16815260200191505060405180910390f35b34801561028057600080fd5b506102b5600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061088b565b6040518082815260200191505060405180910390f35b3480156102d757600080fd5b506102e06108d4565b6040518080602001828103825283818151815260200191508051906020019080838360005b83811015610320578082015181840152602081019050610305565b50505050905090810190601f16801561034d5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561036757600080fd5b506103a6600480360381019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610972565b604051808215151515815260200191505060405180910390f35b3480156103cc57600080fd5b50610421600480360381019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610b0d565b6040518082815260200191505060405180910390f35b60018054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156104cd5780601f106104a2576101008083540402835291602001916104cd565b820191906000526020600020905b8154815290600101906020018083116104b057829003601f168201915b505050505081565b600081600560003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925846040518082815260200191505060405180910390a36001905092915050565b60035481565b600061062182600460008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b9490919063ffffffff16565b600460008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506106f382600560008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b9490919063ffffffff16565b600560008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506107c582600460008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bb690919063ffffffff16565b600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef846040518082815260200191505060405180910390a3600190509392505050565b600260009054906101000a900460ff1681565b6000600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60008054600181600116156101000203166002900480601f01602080910402602001604051908101604052809291908181526020018280546001816001161561010002031660029004801561096a5780601f1061093f5761010080835404028352916020019161096a565b820191906000526020600020905b81548152906001019060200180831161094d57829003601f168201915b505050505081565b60006109c682600460003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b9490919063ffffffff16565b600460003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610a5b82600460008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bb690919063ffffffff16565b600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508273ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef846040518082815260200191505060405180910390a36001905092915050565b6000600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b6000610ba08383610bd8565b1515610bab57600080fd5b818303905092915050565b6000610bc28383610be6565b1515610bcd57600080fd5b818301905092915050565b600081831015905092915050565b60008282840110159050929150505600a165627a7a723058205a62e33bf5d7e96105d7623259a6ac0cd70a71d016410546f3c55a292e6e93db0029",
|
|
"sourceMap": "169:3775:1:-;;;847:253;8:9:-1;5:2;;;30:1;27;20:12;5:2;847:253:1;878:14;;;;;;;;;;;;;;;;;;:6;:14;;;;;;;;;;;;:::i;:::-;;902;;;;;;;;;;;;;;;;;;:4;:14;;;;;;;;;;;;:::i;:::-;;937:2;926:8;;:13;;;;;;;;;;;;;;;;;;985:8;;;;;;;;;;;980:14;;976:2;:18;963:10;:31;949:11;:45;;;;1027:11;;1004:8;:20;1013:10;1004:20;;;;;;;;;;;;;;;:34;;;;1069:10;1048:45;;1065:1;1048:45;;;1081:11;;1048:45;;;;;;;;;;;;;;;;;;169:3775;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;",
|
|
"deployedSourceMap": "169:3775:1:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1179:8;;;467:18;;8:9:-1;5:2;;;30:1;27;20:12;5:2;467:18:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;467:18:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3219:222;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3219:222:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;518:23;;8:9:-1;5:2;;;30:1;27;20:12;5:2;518:23:1;;;;;;;;;;;;;;;;;;;;;;;2592:362;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2592:362:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;491:21;;8:9:-1;5:2;;;30:1;27;20:12;5:2;491:21:1;;;;;;;;;;;;;;;;;;;;;;;;;;;1375:142;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1375:142:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;441:20;;8:9:-1;5:2;;;30:1;27;20:12;5:2;441:20:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;441:20:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1771:261;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1771:261:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3775:167;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3775:167:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;467:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;3219:222::-;3299:12;3359:6;3327:7;:19;3335:10;3327:19;;;;;;;;;;;;;;;:29;3347:8;3327:29;;;;;;;;;;;;;;;:38;;;;3396:8;3375:38;;3384:10;3375:38;;;3406:6;3375:38;;;;;;;;;;;;;;;;;;3430:4;3423:11;;3219:222;;;;:::o;518:23::-;;;;:::o;2592:362::-;2687:12;2733:27;2753:6;2733:8;:15;2742:5;2733:15;;;;;;;;;;;;;;;;:19;;:27;;;;:::i;:::-;2715:8;:15;2724:5;2715:15;;;;;;;;;;;;;;;:45;;;;2799:38;2830:6;2799:7;:14;2807:5;2799:14;;;;;;;;;;;;;;;:26;2814:10;2799:26;;;;;;;;;;;;;;;;:30;;:38;;;;:::i;:::-;2770:7;:14;2778:5;2770:14;;;;;;;;;;;;;;;:26;2785:10;2770:26;;;;;;;;;;;;;;;:67;;;;2863:25;2881:6;2863:8;:13;2872:3;2863:13;;;;;;;;;;;;;;;;:17;;:25;;;;:::i;:::-;2847:8;:13;2856:3;2847:13;;;;;;;;;;;;;;;:41;;;;2914:3;2898:28;;2907:5;2898:28;;;2919:6;2898:28;;;;;;;;;;;;;;;;;;2943:4;2936:11;;2592:362;;;;;:::o;491:21::-;;;;;;;;;;;;;:::o;1375:142::-;1459:12;1494:8;:16;1503:6;1494:16;;;;;;;;;;;;;;;;1487:23;;1375:142;;;:::o;441:20::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;1771:261::-;1831:12;1878:32;1903:6;1878:8;:20;1887:10;1878:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;1855:8;:20;1864:10;1855:20;;;;;;;;;;;;;;;:55;;;;1936:25;1954:6;1936:8;:13;1945:3;1936:13;;;;;;;;;;;;;;;;:17;;:25;;;;:::i;:::-;1920:8;:13;1929:3;1920:13;;;;;;;;;;;;;;;:41;;;;1992:3;1971:33;;1980:10;1971:33;;;1997:6;1971:33;;;;;;;;;;;;;;;;;;2021:4;2014:11;;1771:261;;;;:::o;3775:167::-;3873:14;3910:7;:15;3918:6;3910:15;;;;;;;;;;;;;;;:25;3926:8;3910:25;;;;;;;;;;;;;;;;3903:32;;3775:167;;;;:::o;7704:149:0:-;7780:4;7808:15;7818:1;7821;7808:9;:15::i;:::-;7800:24;;;;;;;;7845:1;7841;:5;7834:12;;7704:149;;;;:::o;7413:::-;7489:4;7517:15;7527:1;7530;7517:9;:15::i;:::-;7509:24;;;;;;;;7554:1;7550;:5;7543:12;;7413:149;;;;:::o;6840:122::-;6922:4;6954:1;6949;:6;;6942:13;;6840:122;;;;:::o;6542:126::-;6624:4;6660:1;6655;6651;:5;:10;;6644:17;;6542:126;;;;:::o",
|
|
"source": "pragma solidity 0.4.24;\n\nimport \"./Math.sol\";\n\n/**\n * Token\n *\n * @title A fixed supply ERC-20 token.\n * https://github.com/ethereum/EIPs/blob/master/EIPS/eip-20.md\n */\ncontract Token {\n using Math for uint;\n event Transfer(\n address indexed _from,\n address indexed _to,\n uint256 _value\n );\n event Approval(\n address indexed _owner,\n address indexed _spender,\n uint256 _value\n );\n string public symbol;\n string public name;\n uint8 public decimals;\n uint public totalSupply;\n mapping(address => uint) balances;\n mapping(address => mapping(address => uint)) allowed;\n /**\n * Constructs the Token contract and gives all of the supply to the address\n * that deployed it. The fixed supply is 1 billion tokens with up to 18\n * decimal places.\n */\n constructor() public {\n symbol = \"TOK\";\n name = \"Token\";\n decimals = 18;\n totalSupply = 1000000000 * 10**uint(decimals);\n balances[msg.sender] = totalSupply;\n Transfer(address(0), msg.sender, totalSupply);\n }\n /**\n * @dev Fallback function\n */\n function() public payable { revert(); }\n /**\n * Gets the token balance of any wallet.\n * @param _owner Wallet address of the returned token balance.\n * @return The balance of tokens in the wallet.\n */\n function balanceOf(address _owner)\n public\n constant\n returns (uint balance)\n {\n return balances[_owner];\n }\n /**\n * Transfers tokens from the sender's wallet to the specified `_to` wallet.\n * @param _to Address of the transfer's recipient.\n * @param _value Number of tokens to transfer.\n * @return True if the transfer succeeded.\n */\n function transfer(address _to, uint _value) public returns (bool success) {\n balances[msg.sender] = balances[msg.sender].sub(_value);\n balances[_to] = balances[_to].add(_value);\n Transfer(msg.sender, _to, _value);\n return true;\n }\n /**\n * Transfer tokens from any wallet to the `_to` wallet. This only works if\n * the `_from` wallet has already allocated tokens for the caller wallet\n * using `approve`. The from wallet must have sufficient balance to\n * transfer. The caller must have sufficient allowance to transfer.\n * @param _from Wallet address that tokens are withdrawn from.\n * @param _to Wallet address that tokens are deposited to.\n * @param _value Number of tokens transacted.\n * @return True if the transfer succeeded.\n */\n function transferFrom(address _from, address _to, uint _value)\n public\n returns (bool success)\n {\n balances[_from] = balances[_from].sub(_value);\n allowed[_from][msg.sender] = allowed[_from][msg.sender].sub(_value);\n balances[_to] = balances[_to].add(_value);\n Transfer(_from, _to, _value);\n return true;\n }\n /**\n * Sender allows another wallet to `transferFrom` tokens from their wallet.\n * @param _spender Address of `transferFrom` recipient.\n * @param _value Number of tokens to `transferFrom`.\n * @return True if the approval succeeded.\n */\n function approve(address _spender, uint _value)\n public\n returns (bool success)\n {\n allowed[msg.sender][_spender] = _value;\n Approval(msg.sender, _spender, _value);\n return true;\n }\n /**\n * Gets the number of tokens that an `_owner` has approved for a _spender\n * to `transferFrom`.\n * @param _owner Wallet address that tokens can be withdrawn from.\n * @param _spender Wallet address that tokens can be deposited to.\n * @return The number of tokens allowed to be transferred.\n */\n function allowance(address _owner, address _spender)\n public\n view\n returns (uint remaining)\n {\n return allowed[_owner][_spender];\n }\n}",
|
|
"sourcePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/MyToken.sol",
|
|
"ast": {
|
|
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/MyToken.sol",
|
|
"exportedSymbols": {
|
|
"Token": [
|
|
1376
|
|
]
|
|
},
|
|
"id": 1377,
|
|
"nodeType": "SourceUnit",
|
|
"nodes": [
|
|
{
|
|
"id": 1130,
|
|
"literals": [
|
|
"solidity",
|
|
"0.4",
|
|
".24"
|
|
],
|
|
"nodeType": "PragmaDirective",
|
|
"src": "0:23:1"
|
|
},
|
|
{
|
|
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/Math.sol",
|
|
"file": "./Math.sol",
|
|
"id": 1131,
|
|
"nodeType": "ImportDirective",
|
|
"scope": 1377,
|
|
"sourceUnit": 1129,
|
|
"src": "25:20:1",
|
|
"symbolAliases": [],
|
|
"unitAlias": ""
|
|
},
|
|
{
|
|
"baseContracts": [],
|
|
"contractDependencies": [],
|
|
"contractKind": "contract",
|
|
"documentation": "Token\n * @title A fixed supply ERC-20 token.\nhttps://github.com/ethereum/EIPs/blob/master/EIPS/eip-20.md",
|
|
"fullyImplemented": true,
|
|
"id": 1376,
|
|
"linearizedBaseContracts": [
|
|
1376
|
|
],
|
|
"name": "Token",
|
|
"nodeType": "ContractDefinition",
|
|
"nodes": [
|
|
{
|
|
"id": 1134,
|
|
"libraryName": {
|
|
"contractScope": null,
|
|
"id": 1132,
|
|
"name": "Math",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 1128,
|
|
"src": "196:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_Math_$1128",
|
|
"typeString": "library Math"
|
|
}
|
|
},
|
|
"nodeType": "UsingForDirective",
|
|
"src": "190:20:1",
|
|
"typeName": {
|
|
"id": 1133,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "205:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"anonymous": false,
|
|
"documentation": null,
|
|
"id": 1142,
|
|
"name": "Transfer",
|
|
"nodeType": "EventDefinition",
|
|
"parameters": {
|
|
"id": 1141,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1136,
|
|
"indexed": true,
|
|
"name": "_from",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1142,
|
|
"src": "239:21:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1135,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "239:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1138,
|
|
"indexed": true,
|
|
"name": "_to",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1142,
|
|
"src": "270:19:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1137,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "270:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1140,
|
|
"indexed": false,
|
|
"name": "_value",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1142,
|
|
"src": "299:14:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 1139,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "299:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "229:90:1"
|
|
},
|
|
"src": "215:105:1"
|
|
},
|
|
{
|
|
"anonymous": false,
|
|
"documentation": null,
|
|
"id": 1150,
|
|
"name": "Approval",
|
|
"nodeType": "EventDefinition",
|
|
"parameters": {
|
|
"id": 1149,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1144,
|
|
"indexed": true,
|
|
"name": "_owner",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1150,
|
|
"src": "349:22:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1143,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "349:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1146,
|
|
"indexed": true,
|
|
"name": "_spender",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1150,
|
|
"src": "381:24:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1145,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "381:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1148,
|
|
"indexed": false,
|
|
"name": "_value",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1150,
|
|
"src": "415:14:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 1147,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "415:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "339:96:1"
|
|
},
|
|
"src": "325:111:1"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1152,
|
|
"name": "symbol",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1376,
|
|
"src": "441:20:1",
|
|
"stateVariable": true,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage",
|
|
"typeString": "string"
|
|
},
|
|
"typeName": {
|
|
"id": 1151,
|
|
"name": "string",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "441:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage_ptr",
|
|
"typeString": "string"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1154,
|
|
"name": "name",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1376,
|
|
"src": "467:18:1",
|
|
"stateVariable": true,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage",
|
|
"typeString": "string"
|
|
},
|
|
"typeName": {
|
|
"id": 1153,
|
|
"name": "string",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "467:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage_ptr",
|
|
"typeString": "string"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1156,
|
|
"name": "decimals",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1376,
|
|
"src": "491:21:1",
|
|
"stateVariable": true,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint8",
|
|
"typeString": "uint8"
|
|
},
|
|
"typeName": {
|
|
"id": 1155,
|
|
"name": "uint8",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "491:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint8",
|
|
"typeString": "uint8"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1158,
|
|
"name": "totalSupply",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1376,
|
|
"src": "518:23:1",
|
|
"stateVariable": true,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 1157,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "518:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1162,
|
|
"name": "balances",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1376,
|
|
"src": "547:33:1",
|
|
"stateVariable": true,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
},
|
|
"typeName": {
|
|
"id": 1161,
|
|
"keyType": {
|
|
"id": 1159,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "555:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Mapping",
|
|
"src": "547:24:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
},
|
|
"valueType": {
|
|
"id": 1160,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "566:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1168,
|
|
"name": "allowed",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1376,
|
|
"src": "586:52:1",
|
|
"stateVariable": true,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$",
|
|
"typeString": "mapping(address => mapping(address => uint256))"
|
|
},
|
|
"typeName": {
|
|
"id": 1167,
|
|
"keyType": {
|
|
"id": 1163,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "594:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Mapping",
|
|
"src": "586:44:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$",
|
|
"typeString": "mapping(address => mapping(address => uint256))"
|
|
},
|
|
"valueType": {
|
|
"id": 1166,
|
|
"keyType": {
|
|
"id": 1164,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "613:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Mapping",
|
|
"src": "605:24:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
},
|
|
"valueType": {
|
|
"id": 1165,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "624:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 1209,
|
|
"nodeType": "Block",
|
|
"src": "868:232:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1173,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 1171,
|
|
"name": "symbol",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1152,
|
|
"src": "878:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage",
|
|
"typeString": "string storage ref"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"hexValue": "544f4b",
|
|
"id": 1172,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "string",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "887:5:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_stringliteral_92ec8c068e88c9c67ad1e93c5fb28a0afc1877fa1cdd216a8e4e432482417ddd",
|
|
"typeString": "literal_string \"TOK\""
|
|
},
|
|
"value": "TOK"
|
|
},
|
|
"src": "878:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage",
|
|
"typeString": "string storage ref"
|
|
}
|
|
},
|
|
"id": 1174,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "878:14:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1177,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 1175,
|
|
"name": "name",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1154,
|
|
"src": "902:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage",
|
|
"typeString": "string storage ref"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"hexValue": "546f6b656e",
|
|
"id": 1176,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "string",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "909:7:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_stringliteral_1317f51c845ce3bfb7c268e5337a825f12f3d0af9584c2bbfbf4e64e314eaf73",
|
|
"typeString": "literal_string \"Token\""
|
|
},
|
|
"value": "Token"
|
|
},
|
|
"src": "902:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage",
|
|
"typeString": "string storage ref"
|
|
}
|
|
},
|
|
"id": 1178,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "902:14:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1181,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 1179,
|
|
"name": "decimals",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1156,
|
|
"src": "926:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint8",
|
|
"typeString": "uint8"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"hexValue": "3138",
|
|
"id": 1180,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "937:2:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_18_by_1",
|
|
"typeString": "int_const 18"
|
|
},
|
|
"value": "18"
|
|
},
|
|
"src": "926:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint8",
|
|
"typeString": "uint8"
|
|
}
|
|
},
|
|
"id": 1182,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "926:13:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1191,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 1183,
|
|
"name": "totalSupply",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1158,
|
|
"src": "949:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 1190,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "31303030303030303030",
|
|
"id": 1184,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "963:10:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_1000000000_by_1",
|
|
"typeString": "int_const 1000000000"
|
|
},
|
|
"value": "1000000000"
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "*",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 1189,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "3130",
|
|
"id": 1185,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "976:2:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_10_by_1",
|
|
"typeString": "int_const 10"
|
|
},
|
|
"value": "10"
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "**",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1187,
|
|
"name": "decimals",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1156,
|
|
"src": "985:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint8",
|
|
"typeString": "uint8"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint8",
|
|
"typeString": "uint8"
|
|
}
|
|
],
|
|
"id": 1186,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "ElementaryTypeNameExpression",
|
|
"src": "980:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_uint256_$",
|
|
"typeString": "type(uint256)"
|
|
},
|
|
"typeName": "uint"
|
|
},
|
|
"id": 1188,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "980:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "976:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "963:31:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "949:45:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1192,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "949:45:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1198,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1193,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "1004:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1196,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1194,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "1013:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1195,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "1013:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "1004:20:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 1197,
|
|
"name": "totalSupply",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1158,
|
|
"src": "1027:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "1004:34:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1199,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "1004:34:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 1202,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "1065:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
}
|
|
],
|
|
"id": 1201,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "ElementaryTypeNameExpression",
|
|
"src": "1057:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_address_$",
|
|
"typeString": "type(address)"
|
|
},
|
|
"typeName": "address"
|
|
},
|
|
"id": 1203,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1057:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1204,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "1069:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1205,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "1069:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1206,
|
|
"name": "totalSupply",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1158,
|
|
"src": "1081:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"id": 1200,
|
|
"name": "Transfer",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1142,
|
|
"src": "1048:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$",
|
|
"typeString": "function (address,address,uint256)"
|
|
}
|
|
},
|
|
"id": 1207,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1048:45:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$__$",
|
|
"typeString": "tuple()"
|
|
}
|
|
},
|
|
"id": 1208,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "1048:45:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": "Constructs the Token contract and gives all of the supply to the address\n that deployed it. The fixed supply is 1 billion tokens with up to 18\n decimal places.",
|
|
"id": 1210,
|
|
"implemented": true,
|
|
"isConstructor": true,
|
|
"isDeclaredConst": false,
|
|
"modifiers": [],
|
|
"name": "",
|
|
"nodeType": "FunctionDefinition",
|
|
"parameters": {
|
|
"id": 1169,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [],
|
|
"src": "858:2:1"
|
|
},
|
|
"payable": false,
|
|
"returnParameters": {
|
|
"id": 1170,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [],
|
|
"src": "868:0:1"
|
|
},
|
|
"scope": 1376,
|
|
"src": "847:253:1",
|
|
"stateMutability": "nonpayable",
|
|
"superFunction": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 1216,
|
|
"nodeType": "Block",
|
|
"src": "1177:13:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [],
|
|
"expression": {
|
|
"argumentTypes": [],
|
|
"id": 1213,
|
|
"name": "revert",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [
|
|
1396,
|
|
1397
|
|
],
|
|
"referencedDeclaration": 1396,
|
|
"src": "1179:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_revert_pure$__$returns$__$",
|
|
"typeString": "function () pure"
|
|
}
|
|
},
|
|
"id": 1214,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1179:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$__$",
|
|
"typeString": "tuple()"
|
|
}
|
|
},
|
|
"id": 1215,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "1179:8:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": "@dev Fallback function",
|
|
"id": 1217,
|
|
"implemented": true,
|
|
"isConstructor": false,
|
|
"isDeclaredConst": false,
|
|
"modifiers": [],
|
|
"name": "",
|
|
"nodeType": "FunctionDefinition",
|
|
"parameters": {
|
|
"id": 1211,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [],
|
|
"src": "1159:2:1"
|
|
},
|
|
"payable": true,
|
|
"returnParameters": {
|
|
"id": 1212,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [],
|
|
"src": "1177:0:1"
|
|
},
|
|
"scope": 1376,
|
|
"src": "1151:39:1",
|
|
"stateMutability": "payable",
|
|
"superFunction": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 1228,
|
|
"nodeType": "Block",
|
|
"src": "1477:40:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1224,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "1494:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1226,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1225,
|
|
"name": "_owner",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1219,
|
|
"src": "1503:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "1494:16:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"functionReturnParameters": 1223,
|
|
"id": 1227,
|
|
"nodeType": "Return",
|
|
"src": "1487:23:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": "Gets the token balance of any wallet.\n@param _owner Wallet address of the returned token balance.\n@return The balance of tokens in the wallet.",
|
|
"id": 1229,
|
|
"implemented": true,
|
|
"isConstructor": false,
|
|
"isDeclaredConst": true,
|
|
"modifiers": [],
|
|
"name": "balanceOf",
|
|
"nodeType": "FunctionDefinition",
|
|
"parameters": {
|
|
"id": 1220,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1219,
|
|
"name": "_owner",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1229,
|
|
"src": "1394:14:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1218,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1394:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "1393:16:1"
|
|
},
|
|
"payable": false,
|
|
"returnParameters": {
|
|
"id": 1223,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1222,
|
|
"name": "balance",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1229,
|
|
"src": "1459:12:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 1221,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1459:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "1458:14:1"
|
|
},
|
|
"scope": 1376,
|
|
"src": "1375:142:1",
|
|
"stateMutability": "view",
|
|
"superFunction": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 1271,
|
|
"nodeType": "Block",
|
|
"src": "1845:187:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1249,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1238,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "1855:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1241,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1239,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "1864:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1240,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "1864:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "1855:20:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1247,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1233,
|
|
"src": "1903:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1242,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "1878:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1245,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1243,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "1887:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1244,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "1887:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "1878:20:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1246,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sub",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 955,
|
|
"src": "1878:24:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
|
|
"typeString": "function (uint256,uint256) pure returns (uint256)"
|
|
}
|
|
},
|
|
"id": 1248,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1878:32:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "1855:55:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1250,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "1855:55:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1260,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1251,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "1920:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1253,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1252,
|
|
"name": "_to",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1231,
|
|
"src": "1929:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "1920:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1258,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1233,
|
|
"src": "1954:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1254,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "1936:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1256,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1255,
|
|
"name": "_to",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1231,
|
|
"src": "1945:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "1936:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1257,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "add",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 934,
|
|
"src": "1936:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
|
|
"typeString": "function (uint256,uint256) pure returns (uint256)"
|
|
}
|
|
},
|
|
"id": 1259,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1936:25:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "1920:41:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1261,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "1920:41:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1263,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "1980:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1264,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "1980:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1265,
|
|
"name": "_to",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1231,
|
|
"src": "1992:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1266,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1233,
|
|
"src": "1997:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"id": 1262,
|
|
"name": "Transfer",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1142,
|
|
"src": "1971:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$",
|
|
"typeString": "function (address,address,uint256)"
|
|
}
|
|
},
|
|
"id": 1267,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1971:33:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$__$",
|
|
"typeString": "tuple()"
|
|
}
|
|
},
|
|
"id": 1268,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "1971:33:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "74727565",
|
|
"id": 1269,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "bool",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "2021:4:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"value": "true"
|
|
},
|
|
"functionReturnParameters": 1237,
|
|
"id": 1270,
|
|
"nodeType": "Return",
|
|
"src": "2014:11:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": "Transfers tokens from the sender's wallet to the specified `_to` wallet.\n@param _to Address of the transfer's recipient.\n@param _value Number of tokens to transfer.\n@return True if the transfer succeeded.",
|
|
"id": 1272,
|
|
"implemented": true,
|
|
"isConstructor": false,
|
|
"isDeclaredConst": false,
|
|
"modifiers": [],
|
|
"name": "transfer",
|
|
"nodeType": "FunctionDefinition",
|
|
"parameters": {
|
|
"id": 1234,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1231,
|
|
"name": "_to",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1272,
|
|
"src": "1789:11:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1230,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1789:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1233,
|
|
"name": "_value",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1272,
|
|
"src": "1802:11:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 1232,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1802:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "1788:26:1"
|
|
},
|
|
"payable": false,
|
|
"returnParameters": {
|
|
"id": 1237,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1236,
|
|
"name": "success",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1272,
|
|
"src": "1831:12:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"typeName": {
|
|
"id": 1235,
|
|
"name": "bool",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1831:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "1830:14:1"
|
|
},
|
|
"scope": 1376,
|
|
"src": "1771:261:1",
|
|
"stateMutability": "nonpayable",
|
|
"superFunction": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 1330,
|
|
"nodeType": "Block",
|
|
"src": "2705:249:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1292,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1283,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "2715:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1285,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1284,
|
|
"name": "_from",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1274,
|
|
"src": "2724:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2715:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1290,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1278,
|
|
"src": "2753:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1286,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "2733:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1288,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1287,
|
|
"name": "_from",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1274,
|
|
"src": "2742:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2733:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1289,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sub",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 955,
|
|
"src": "2733:19:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
|
|
"typeString": "function (uint256,uint256) pure returns (uint256)"
|
|
}
|
|
},
|
|
"id": 1291,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2733:27:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "2715:45:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1293,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "2715:45:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1309,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1294,
|
|
"name": "allowed",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1168,
|
|
"src": "2770:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$",
|
|
"typeString": "mapping(address => mapping(address => uint256))"
|
|
}
|
|
},
|
|
"id": 1298,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1295,
|
|
"name": "_from",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1274,
|
|
"src": "2778:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2770:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1299,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1296,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "2785:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1297,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "2785:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2770:26:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1307,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1278,
|
|
"src": "2830:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1300,
|
|
"name": "allowed",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1168,
|
|
"src": "2799:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$",
|
|
"typeString": "mapping(address => mapping(address => uint256))"
|
|
}
|
|
},
|
|
"id": 1302,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1301,
|
|
"name": "_from",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1274,
|
|
"src": "2807:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2799:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1305,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1303,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "2814:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1304,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "2814:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2799:26:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1306,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sub",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 955,
|
|
"src": "2799:30:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
|
|
"typeString": "function (uint256,uint256) pure returns (uint256)"
|
|
}
|
|
},
|
|
"id": 1308,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2799:38:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "2770:67:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1310,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "2770:67:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1320,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1311,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "2847:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1313,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1312,
|
|
"name": "_to",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1276,
|
|
"src": "2856:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2847:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1318,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1278,
|
|
"src": "2881:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1314,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "2863:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1316,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1315,
|
|
"name": "_to",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1276,
|
|
"src": "2872:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2863:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1317,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "add",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 934,
|
|
"src": "2863:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
|
|
"typeString": "function (uint256,uint256) pure returns (uint256)"
|
|
}
|
|
},
|
|
"id": 1319,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2863:25:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "2847:41:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1321,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "2847:41:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1323,
|
|
"name": "_from",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1274,
|
|
"src": "2907:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1324,
|
|
"name": "_to",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1276,
|
|
"src": "2914:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1325,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1278,
|
|
"src": "2919:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"id": 1322,
|
|
"name": "Transfer",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1142,
|
|
"src": "2898:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$",
|
|
"typeString": "function (address,address,uint256)"
|
|
}
|
|
},
|
|
"id": 1326,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2898:28:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$__$",
|
|
"typeString": "tuple()"
|
|
}
|
|
},
|
|
"id": 1327,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "2898:28:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "74727565",
|
|
"id": 1328,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "bool",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "2943:4:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"value": "true"
|
|
},
|
|
"functionReturnParameters": 1282,
|
|
"id": 1329,
|
|
"nodeType": "Return",
|
|
"src": "2936:11:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": "Transfer tokens from any wallet to the `_to` wallet. This only works if\n the `_from` wallet has already allocated tokens for the caller wallet\n using `approve`. The from wallet must have sufficient balance to\n transfer. The caller must have sufficient allowance to transfer.\n@param _from Wallet address that tokens are withdrawn from.\n@param _to Wallet address that tokens are deposited to.\n@param _value Number of tokens transacted.\n@return True if the transfer succeeded.",
|
|
"id": 1331,
|
|
"implemented": true,
|
|
"isConstructor": false,
|
|
"isDeclaredConst": false,
|
|
"modifiers": [],
|
|
"name": "transferFrom",
|
|
"nodeType": "FunctionDefinition",
|
|
"parameters": {
|
|
"id": 1279,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1274,
|
|
"name": "_from",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1331,
|
|
"src": "2614:13:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1273,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2614:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1276,
|
|
"name": "_to",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1331,
|
|
"src": "2629:11:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1275,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2629:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1278,
|
|
"name": "_value",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1331,
|
|
"src": "2642:11:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 1277,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2642:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "2613:41:1"
|
|
},
|
|
"payable": false,
|
|
"returnParameters": {
|
|
"id": 1282,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1281,
|
|
"name": "success",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1331,
|
|
"src": "2687:12:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"typeName": {
|
|
"id": 1280,
|
|
"name": "bool",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2687:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "2686:14:1"
|
|
},
|
|
"scope": 1376,
|
|
"src": "2592:362:1",
|
|
"stateMutability": "nonpayable",
|
|
"superFunction": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 1358,
|
|
"nodeType": "Block",
|
|
"src": "3317:124:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1347,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1340,
|
|
"name": "allowed",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1168,
|
|
"src": "3327:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$",
|
|
"typeString": "mapping(address => mapping(address => uint256))"
|
|
}
|
|
},
|
|
"id": 1344,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1341,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "3335:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1342,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "3335:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "3327:19:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1345,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1343,
|
|
"name": "_spender",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1333,
|
|
"src": "3347:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "3327:29:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 1346,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1335,
|
|
"src": "3359:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "3327:38:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1348,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "3327:38:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1350,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "3384:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1351,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "3384:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1352,
|
|
"name": "_spender",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1333,
|
|
"src": "3396:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1353,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1335,
|
|
"src": "3406:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"id": 1349,
|
|
"name": "Approval",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1150,
|
|
"src": "3375:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$",
|
|
"typeString": "function (address,address,uint256)"
|
|
}
|
|
},
|
|
"id": 1354,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "3375:38:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$__$",
|
|
"typeString": "tuple()"
|
|
}
|
|
},
|
|
"id": 1355,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "3375:38:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "74727565",
|
|
"id": 1356,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "bool",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "3430:4:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"value": "true"
|
|
},
|
|
"functionReturnParameters": 1339,
|
|
"id": 1357,
|
|
"nodeType": "Return",
|
|
"src": "3423:11:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": "Sender allows another wallet to `transferFrom` tokens from their wallet.\n@param _spender Address of `transferFrom` recipient.\n@param _value Number of tokens to `transferFrom`.\n@return True if the approval succeeded.",
|
|
"id": 1359,
|
|
"implemented": true,
|
|
"isConstructor": false,
|
|
"isDeclaredConst": false,
|
|
"modifiers": [],
|
|
"name": "approve",
|
|
"nodeType": "FunctionDefinition",
|
|
"parameters": {
|
|
"id": 1336,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1333,
|
|
"name": "_spender",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1359,
|
|
"src": "3236:16:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1332,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3236:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1335,
|
|
"name": "_value",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1359,
|
|
"src": "3254:11:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 1334,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3254:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "3235:31:1"
|
|
},
|
|
"payable": false,
|
|
"returnParameters": {
|
|
"id": 1339,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1338,
|
|
"name": "success",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1359,
|
|
"src": "3299:12:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"typeName": {
|
|
"id": 1337,
|
|
"name": "bool",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3299:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "3298:14:1"
|
|
},
|
|
"scope": 1376,
|
|
"src": "3219:222:1",
|
|
"stateMutability": "nonpayable",
|
|
"superFunction": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 1374,
|
|
"nodeType": "Block",
|
|
"src": "3893:49:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1368,
|
|
"name": "allowed",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1168,
|
|
"src": "3910:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$",
|
|
"typeString": "mapping(address => mapping(address => uint256))"
|
|
}
|
|
},
|
|
"id": 1370,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1369,
|
|
"name": "_owner",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1361,
|
|
"src": "3918:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "3910:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1372,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1371,
|
|
"name": "_spender",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1363,
|
|
"src": "3926:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "3910:25:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"functionReturnParameters": 1367,
|
|
"id": 1373,
|
|
"nodeType": "Return",
|
|
"src": "3903:32:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": "Gets the number of tokens that an `_owner` has approved for a _spender\n to `transferFrom`.\n@param _owner Wallet address that tokens can be withdrawn from.\n@param _spender Wallet address that tokens can be deposited to.\n@return The number of tokens allowed to be transferred.",
|
|
"id": 1375,
|
|
"implemented": true,
|
|
"isConstructor": false,
|
|
"isDeclaredConst": true,
|
|
"modifiers": [],
|
|
"name": "allowance",
|
|
"nodeType": "FunctionDefinition",
|
|
"parameters": {
|
|
"id": 1364,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1361,
|
|
"name": "_owner",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1375,
|
|
"src": "3794:14:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1360,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3794:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1363,
|
|
"name": "_spender",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1375,
|
|
"src": "3810:16:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1362,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3810:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "3793:34:1"
|
|
},
|
|
"payable": false,
|
|
"returnParameters": {
|
|
"id": 1367,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1366,
|
|
"name": "remaining",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1375,
|
|
"src": "3873:14:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 1365,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3873:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "3872:16:1"
|
|
},
|
|
"scope": 1376,
|
|
"src": "3775:167:1",
|
|
"stateMutability": "view",
|
|
"superFunction": null,
|
|
"visibility": "public"
|
|
}
|
|
],
|
|
"scope": 1377,
|
|
"src": "169:3775:1"
|
|
}
|
|
],
|
|
"src": "0:3944:1"
|
|
},
|
|
"legacyAST": {
|
|
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/MyToken.sol",
|
|
"exportedSymbols": {
|
|
"Token": [
|
|
1376
|
|
]
|
|
},
|
|
"id": 1377,
|
|
"nodeType": "SourceUnit",
|
|
"nodes": [
|
|
{
|
|
"id": 1130,
|
|
"literals": [
|
|
"solidity",
|
|
"0.4",
|
|
".24"
|
|
],
|
|
"nodeType": "PragmaDirective",
|
|
"src": "0:23:1"
|
|
},
|
|
{
|
|
"absolutePath": "/Users/apanizo/git/gnosis/safe-contracts/contracts/Math.sol",
|
|
"file": "./Math.sol",
|
|
"id": 1131,
|
|
"nodeType": "ImportDirective",
|
|
"scope": 1377,
|
|
"sourceUnit": 1129,
|
|
"src": "25:20:1",
|
|
"symbolAliases": [],
|
|
"unitAlias": ""
|
|
},
|
|
{
|
|
"baseContracts": [],
|
|
"contractDependencies": [],
|
|
"contractKind": "contract",
|
|
"documentation": "Token\n * @title A fixed supply ERC-20 token.\nhttps://github.com/ethereum/EIPs/blob/master/EIPS/eip-20.md",
|
|
"fullyImplemented": true,
|
|
"id": 1376,
|
|
"linearizedBaseContracts": [
|
|
1376
|
|
],
|
|
"name": "Token",
|
|
"nodeType": "ContractDefinition",
|
|
"nodes": [
|
|
{
|
|
"id": 1134,
|
|
"libraryName": {
|
|
"contractScope": null,
|
|
"id": 1132,
|
|
"name": "Math",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 1128,
|
|
"src": "196:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_Math_$1128",
|
|
"typeString": "library Math"
|
|
}
|
|
},
|
|
"nodeType": "UsingForDirective",
|
|
"src": "190:20:1",
|
|
"typeName": {
|
|
"id": 1133,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "205:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"anonymous": false,
|
|
"documentation": null,
|
|
"id": 1142,
|
|
"name": "Transfer",
|
|
"nodeType": "EventDefinition",
|
|
"parameters": {
|
|
"id": 1141,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1136,
|
|
"indexed": true,
|
|
"name": "_from",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1142,
|
|
"src": "239:21:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1135,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "239:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1138,
|
|
"indexed": true,
|
|
"name": "_to",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1142,
|
|
"src": "270:19:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1137,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "270:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1140,
|
|
"indexed": false,
|
|
"name": "_value",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1142,
|
|
"src": "299:14:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 1139,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "299:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "229:90:1"
|
|
},
|
|
"src": "215:105:1"
|
|
},
|
|
{
|
|
"anonymous": false,
|
|
"documentation": null,
|
|
"id": 1150,
|
|
"name": "Approval",
|
|
"nodeType": "EventDefinition",
|
|
"parameters": {
|
|
"id": 1149,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1144,
|
|
"indexed": true,
|
|
"name": "_owner",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1150,
|
|
"src": "349:22:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1143,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "349:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1146,
|
|
"indexed": true,
|
|
"name": "_spender",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1150,
|
|
"src": "381:24:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1145,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "381:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1148,
|
|
"indexed": false,
|
|
"name": "_value",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1150,
|
|
"src": "415:14:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 1147,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "415:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "339:96:1"
|
|
},
|
|
"src": "325:111:1"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1152,
|
|
"name": "symbol",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1376,
|
|
"src": "441:20:1",
|
|
"stateVariable": true,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage",
|
|
"typeString": "string"
|
|
},
|
|
"typeName": {
|
|
"id": 1151,
|
|
"name": "string",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "441:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage_ptr",
|
|
"typeString": "string"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1154,
|
|
"name": "name",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1376,
|
|
"src": "467:18:1",
|
|
"stateVariable": true,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage",
|
|
"typeString": "string"
|
|
},
|
|
"typeName": {
|
|
"id": 1153,
|
|
"name": "string",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "467:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage_ptr",
|
|
"typeString": "string"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1156,
|
|
"name": "decimals",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1376,
|
|
"src": "491:21:1",
|
|
"stateVariable": true,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint8",
|
|
"typeString": "uint8"
|
|
},
|
|
"typeName": {
|
|
"id": 1155,
|
|
"name": "uint8",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "491:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint8",
|
|
"typeString": "uint8"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1158,
|
|
"name": "totalSupply",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1376,
|
|
"src": "518:23:1",
|
|
"stateVariable": true,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 1157,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "518:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1162,
|
|
"name": "balances",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1376,
|
|
"src": "547:33:1",
|
|
"stateVariable": true,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
},
|
|
"typeName": {
|
|
"id": 1161,
|
|
"keyType": {
|
|
"id": 1159,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "555:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Mapping",
|
|
"src": "547:24:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
},
|
|
"valueType": {
|
|
"id": 1160,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "566:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1168,
|
|
"name": "allowed",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1376,
|
|
"src": "586:52:1",
|
|
"stateVariable": true,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$",
|
|
"typeString": "mapping(address => mapping(address => uint256))"
|
|
},
|
|
"typeName": {
|
|
"id": 1167,
|
|
"keyType": {
|
|
"id": 1163,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "594:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Mapping",
|
|
"src": "586:44:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$",
|
|
"typeString": "mapping(address => mapping(address => uint256))"
|
|
},
|
|
"valueType": {
|
|
"id": 1166,
|
|
"keyType": {
|
|
"id": 1164,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "613:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Mapping",
|
|
"src": "605:24:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
},
|
|
"valueType": {
|
|
"id": 1165,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "624:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 1209,
|
|
"nodeType": "Block",
|
|
"src": "868:232:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1173,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 1171,
|
|
"name": "symbol",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1152,
|
|
"src": "878:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage",
|
|
"typeString": "string storage ref"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"hexValue": "544f4b",
|
|
"id": 1172,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "string",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "887:5:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_stringliteral_92ec8c068e88c9c67ad1e93c5fb28a0afc1877fa1cdd216a8e4e432482417ddd",
|
|
"typeString": "literal_string \"TOK\""
|
|
},
|
|
"value": "TOK"
|
|
},
|
|
"src": "878:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage",
|
|
"typeString": "string storage ref"
|
|
}
|
|
},
|
|
"id": 1174,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "878:14:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1177,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 1175,
|
|
"name": "name",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1154,
|
|
"src": "902:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage",
|
|
"typeString": "string storage ref"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"hexValue": "546f6b656e",
|
|
"id": 1176,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "string",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "909:7:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_stringliteral_1317f51c845ce3bfb7c268e5337a825f12f3d0af9584c2bbfbf4e64e314eaf73",
|
|
"typeString": "literal_string \"Token\""
|
|
},
|
|
"value": "Token"
|
|
},
|
|
"src": "902:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_string_storage",
|
|
"typeString": "string storage ref"
|
|
}
|
|
},
|
|
"id": 1178,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "902:14:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1181,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 1179,
|
|
"name": "decimals",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1156,
|
|
"src": "926:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint8",
|
|
"typeString": "uint8"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"hexValue": "3138",
|
|
"id": 1180,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "937:2:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_18_by_1",
|
|
"typeString": "int_const 18"
|
|
},
|
|
"value": "18"
|
|
},
|
|
"src": "926:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint8",
|
|
"typeString": "uint8"
|
|
}
|
|
},
|
|
"id": 1182,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "926:13:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1191,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 1183,
|
|
"name": "totalSupply",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1158,
|
|
"src": "949:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 1190,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "31303030303030303030",
|
|
"id": 1184,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "963:10:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_1000000000_by_1",
|
|
"typeString": "int_const 1000000000"
|
|
},
|
|
"value": "1000000000"
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "*",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 1189,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "3130",
|
|
"id": 1185,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "976:2:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_10_by_1",
|
|
"typeString": "int_const 10"
|
|
},
|
|
"value": "10"
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "**",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1187,
|
|
"name": "decimals",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1156,
|
|
"src": "985:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint8",
|
|
"typeString": "uint8"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint8",
|
|
"typeString": "uint8"
|
|
}
|
|
],
|
|
"id": 1186,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "ElementaryTypeNameExpression",
|
|
"src": "980:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_uint256_$",
|
|
"typeString": "type(uint256)"
|
|
},
|
|
"typeName": "uint"
|
|
},
|
|
"id": 1188,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "980:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "976:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "963:31:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "949:45:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1192,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "949:45:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1198,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1193,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "1004:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1196,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1194,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "1013:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1195,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "1013:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "1004:20:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 1197,
|
|
"name": "totalSupply",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1158,
|
|
"src": "1027:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "1004:34:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1199,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "1004:34:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 1202,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "1065:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
}
|
|
],
|
|
"id": 1201,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "ElementaryTypeNameExpression",
|
|
"src": "1057:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_address_$",
|
|
"typeString": "type(address)"
|
|
},
|
|
"typeName": "address"
|
|
},
|
|
"id": 1203,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1057:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1204,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "1069:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1205,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "1069:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1206,
|
|
"name": "totalSupply",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1158,
|
|
"src": "1081:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"id": 1200,
|
|
"name": "Transfer",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1142,
|
|
"src": "1048:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$",
|
|
"typeString": "function (address,address,uint256)"
|
|
}
|
|
},
|
|
"id": 1207,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1048:45:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$__$",
|
|
"typeString": "tuple()"
|
|
}
|
|
},
|
|
"id": 1208,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "1048:45:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": "Constructs the Token contract and gives all of the supply to the address\n that deployed it. The fixed supply is 1 billion tokens with up to 18\n decimal places.",
|
|
"id": 1210,
|
|
"implemented": true,
|
|
"isConstructor": true,
|
|
"isDeclaredConst": false,
|
|
"modifiers": [],
|
|
"name": "",
|
|
"nodeType": "FunctionDefinition",
|
|
"parameters": {
|
|
"id": 1169,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [],
|
|
"src": "858:2:1"
|
|
},
|
|
"payable": false,
|
|
"returnParameters": {
|
|
"id": 1170,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [],
|
|
"src": "868:0:1"
|
|
},
|
|
"scope": 1376,
|
|
"src": "847:253:1",
|
|
"stateMutability": "nonpayable",
|
|
"superFunction": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 1216,
|
|
"nodeType": "Block",
|
|
"src": "1177:13:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [],
|
|
"expression": {
|
|
"argumentTypes": [],
|
|
"id": 1213,
|
|
"name": "revert",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [
|
|
1396,
|
|
1397
|
|
],
|
|
"referencedDeclaration": 1396,
|
|
"src": "1179:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_revert_pure$__$returns$__$",
|
|
"typeString": "function () pure"
|
|
}
|
|
},
|
|
"id": 1214,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1179:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$__$",
|
|
"typeString": "tuple()"
|
|
}
|
|
},
|
|
"id": 1215,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "1179:8:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": "@dev Fallback function",
|
|
"id": 1217,
|
|
"implemented": true,
|
|
"isConstructor": false,
|
|
"isDeclaredConst": false,
|
|
"modifiers": [],
|
|
"name": "",
|
|
"nodeType": "FunctionDefinition",
|
|
"parameters": {
|
|
"id": 1211,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [],
|
|
"src": "1159:2:1"
|
|
},
|
|
"payable": true,
|
|
"returnParameters": {
|
|
"id": 1212,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [],
|
|
"src": "1177:0:1"
|
|
},
|
|
"scope": 1376,
|
|
"src": "1151:39:1",
|
|
"stateMutability": "payable",
|
|
"superFunction": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 1228,
|
|
"nodeType": "Block",
|
|
"src": "1477:40:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1224,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "1494:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1226,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1225,
|
|
"name": "_owner",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1219,
|
|
"src": "1503:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "1494:16:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"functionReturnParameters": 1223,
|
|
"id": 1227,
|
|
"nodeType": "Return",
|
|
"src": "1487:23:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": "Gets the token balance of any wallet.\n@param _owner Wallet address of the returned token balance.\n@return The balance of tokens in the wallet.",
|
|
"id": 1229,
|
|
"implemented": true,
|
|
"isConstructor": false,
|
|
"isDeclaredConst": true,
|
|
"modifiers": [],
|
|
"name": "balanceOf",
|
|
"nodeType": "FunctionDefinition",
|
|
"parameters": {
|
|
"id": 1220,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1219,
|
|
"name": "_owner",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1229,
|
|
"src": "1394:14:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1218,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1394:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "1393:16:1"
|
|
},
|
|
"payable": false,
|
|
"returnParameters": {
|
|
"id": 1223,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1222,
|
|
"name": "balance",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1229,
|
|
"src": "1459:12:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 1221,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1459:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "1458:14:1"
|
|
},
|
|
"scope": 1376,
|
|
"src": "1375:142:1",
|
|
"stateMutability": "view",
|
|
"superFunction": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 1271,
|
|
"nodeType": "Block",
|
|
"src": "1845:187:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1249,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1238,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "1855:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1241,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1239,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "1864:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1240,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "1864:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "1855:20:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1247,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1233,
|
|
"src": "1903:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1242,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "1878:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1245,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1243,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "1887:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1244,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "1887:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "1878:20:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1246,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sub",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 955,
|
|
"src": "1878:24:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
|
|
"typeString": "function (uint256,uint256) pure returns (uint256)"
|
|
}
|
|
},
|
|
"id": 1248,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1878:32:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "1855:55:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1250,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "1855:55:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1260,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1251,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "1920:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1253,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1252,
|
|
"name": "_to",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1231,
|
|
"src": "1929:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "1920:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1258,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1233,
|
|
"src": "1954:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1254,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "1936:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1256,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1255,
|
|
"name": "_to",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1231,
|
|
"src": "1945:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "1936:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1257,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "add",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 934,
|
|
"src": "1936:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
|
|
"typeString": "function (uint256,uint256) pure returns (uint256)"
|
|
}
|
|
},
|
|
"id": 1259,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1936:25:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "1920:41:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1261,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "1920:41:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1263,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "1980:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1264,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "1980:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1265,
|
|
"name": "_to",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1231,
|
|
"src": "1992:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1266,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1233,
|
|
"src": "1997:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"id": 1262,
|
|
"name": "Transfer",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1142,
|
|
"src": "1971:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$",
|
|
"typeString": "function (address,address,uint256)"
|
|
}
|
|
},
|
|
"id": 1267,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1971:33:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$__$",
|
|
"typeString": "tuple()"
|
|
}
|
|
},
|
|
"id": 1268,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "1971:33:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "74727565",
|
|
"id": 1269,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "bool",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "2021:4:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"value": "true"
|
|
},
|
|
"functionReturnParameters": 1237,
|
|
"id": 1270,
|
|
"nodeType": "Return",
|
|
"src": "2014:11:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": "Transfers tokens from the sender's wallet to the specified `_to` wallet.\n@param _to Address of the transfer's recipient.\n@param _value Number of tokens to transfer.\n@return True if the transfer succeeded.",
|
|
"id": 1272,
|
|
"implemented": true,
|
|
"isConstructor": false,
|
|
"isDeclaredConst": false,
|
|
"modifiers": [],
|
|
"name": "transfer",
|
|
"nodeType": "FunctionDefinition",
|
|
"parameters": {
|
|
"id": 1234,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1231,
|
|
"name": "_to",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1272,
|
|
"src": "1789:11:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1230,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1789:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1233,
|
|
"name": "_value",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1272,
|
|
"src": "1802:11:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 1232,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1802:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "1788:26:1"
|
|
},
|
|
"payable": false,
|
|
"returnParameters": {
|
|
"id": 1237,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1236,
|
|
"name": "success",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1272,
|
|
"src": "1831:12:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"typeName": {
|
|
"id": 1235,
|
|
"name": "bool",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1831:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "1830:14:1"
|
|
},
|
|
"scope": 1376,
|
|
"src": "1771:261:1",
|
|
"stateMutability": "nonpayable",
|
|
"superFunction": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 1330,
|
|
"nodeType": "Block",
|
|
"src": "2705:249:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1292,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1283,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "2715:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1285,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1284,
|
|
"name": "_from",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1274,
|
|
"src": "2724:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2715:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1290,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1278,
|
|
"src": "2753:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1286,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "2733:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1288,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1287,
|
|
"name": "_from",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1274,
|
|
"src": "2742:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2733:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1289,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sub",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 955,
|
|
"src": "2733:19:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
|
|
"typeString": "function (uint256,uint256) pure returns (uint256)"
|
|
}
|
|
},
|
|
"id": 1291,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2733:27:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "2715:45:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1293,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "2715:45:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1309,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1294,
|
|
"name": "allowed",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1168,
|
|
"src": "2770:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$",
|
|
"typeString": "mapping(address => mapping(address => uint256))"
|
|
}
|
|
},
|
|
"id": 1298,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1295,
|
|
"name": "_from",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1274,
|
|
"src": "2778:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2770:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1299,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1296,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "2785:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1297,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "2785:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2770:26:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1307,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1278,
|
|
"src": "2830:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1300,
|
|
"name": "allowed",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1168,
|
|
"src": "2799:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$",
|
|
"typeString": "mapping(address => mapping(address => uint256))"
|
|
}
|
|
},
|
|
"id": 1302,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1301,
|
|
"name": "_from",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1274,
|
|
"src": "2807:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2799:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1305,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1303,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "2814:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1304,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "2814:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2799:26:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1306,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sub",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 955,
|
|
"src": "2799:30:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
|
|
"typeString": "function (uint256,uint256) pure returns (uint256)"
|
|
}
|
|
},
|
|
"id": 1308,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2799:38:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "2770:67:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1310,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "2770:67:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1320,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1311,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "2847:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1313,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1312,
|
|
"name": "_to",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1276,
|
|
"src": "2856:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2847:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1318,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1278,
|
|
"src": "2881:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1314,
|
|
"name": "balances",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1162,
|
|
"src": "2863:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1316,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1315,
|
|
"name": "_to",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1276,
|
|
"src": "2872:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2863:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1317,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "add",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 934,
|
|
"src": "2863:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
|
|
"typeString": "function (uint256,uint256) pure returns (uint256)"
|
|
}
|
|
},
|
|
"id": 1319,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2863:25:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "2847:41:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1321,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "2847:41:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1323,
|
|
"name": "_from",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1274,
|
|
"src": "2907:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1324,
|
|
"name": "_to",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1276,
|
|
"src": "2914:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1325,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1278,
|
|
"src": "2919:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"id": 1322,
|
|
"name": "Transfer",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1142,
|
|
"src": "2898:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$",
|
|
"typeString": "function (address,address,uint256)"
|
|
}
|
|
},
|
|
"id": 1326,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2898:28:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$__$",
|
|
"typeString": "tuple()"
|
|
}
|
|
},
|
|
"id": 1327,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "2898:28:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "74727565",
|
|
"id": 1328,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "bool",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "2943:4:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"value": "true"
|
|
},
|
|
"functionReturnParameters": 1282,
|
|
"id": 1329,
|
|
"nodeType": "Return",
|
|
"src": "2936:11:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": "Transfer tokens from any wallet to the `_to` wallet. This only works if\n the `_from` wallet has already allocated tokens for the caller wallet\n using `approve`. The from wallet must have sufficient balance to\n transfer. The caller must have sufficient allowance to transfer.\n@param _from Wallet address that tokens are withdrawn from.\n@param _to Wallet address that tokens are deposited to.\n@param _value Number of tokens transacted.\n@return True if the transfer succeeded.",
|
|
"id": 1331,
|
|
"implemented": true,
|
|
"isConstructor": false,
|
|
"isDeclaredConst": false,
|
|
"modifiers": [],
|
|
"name": "transferFrom",
|
|
"nodeType": "FunctionDefinition",
|
|
"parameters": {
|
|
"id": 1279,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1274,
|
|
"name": "_from",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1331,
|
|
"src": "2614:13:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1273,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2614:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1276,
|
|
"name": "_to",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1331,
|
|
"src": "2629:11:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1275,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2629:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1278,
|
|
"name": "_value",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1331,
|
|
"src": "2642:11:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 1277,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2642:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "2613:41:1"
|
|
},
|
|
"payable": false,
|
|
"returnParameters": {
|
|
"id": 1282,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1281,
|
|
"name": "success",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1331,
|
|
"src": "2687:12:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"typeName": {
|
|
"id": 1280,
|
|
"name": "bool",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2687:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "2686:14:1"
|
|
},
|
|
"scope": 1376,
|
|
"src": "2592:362:1",
|
|
"stateMutability": "nonpayable",
|
|
"superFunction": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 1358,
|
|
"nodeType": "Block",
|
|
"src": "3317:124:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1347,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1340,
|
|
"name": "allowed",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1168,
|
|
"src": "3327:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$",
|
|
"typeString": "mapping(address => mapping(address => uint256))"
|
|
}
|
|
},
|
|
"id": 1344,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1341,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "3335:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1342,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "3335:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "3327:19:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1345,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1343,
|
|
"name": "_spender",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1333,
|
|
"src": "3347:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "3327:29:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 1346,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1335,
|
|
"src": "3359:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "3327:38:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 1348,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "3327:38:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 1350,
|
|
"name": "msg",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1391,
|
|
"src": "3384:3:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_magic_message",
|
|
"typeString": "msg"
|
|
}
|
|
},
|
|
"id": 1351,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "sender",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "3384:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1352,
|
|
"name": "_spender",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1333,
|
|
"src": "3396:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1353,
|
|
"name": "_value",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1335,
|
|
"src": "3406:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"id": 1349,
|
|
"name": "Approval",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1150,
|
|
"src": "3375:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$",
|
|
"typeString": "function (address,address,uint256)"
|
|
}
|
|
},
|
|
"id": 1354,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "3375:38:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_tuple$__$",
|
|
"typeString": "tuple()"
|
|
}
|
|
},
|
|
"id": 1355,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "3375:38:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "74727565",
|
|
"id": 1356,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "bool",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "3430:4:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"value": "true"
|
|
},
|
|
"functionReturnParameters": 1339,
|
|
"id": 1357,
|
|
"nodeType": "Return",
|
|
"src": "3423:11:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": "Sender allows another wallet to `transferFrom` tokens from their wallet.\n@param _spender Address of `transferFrom` recipient.\n@param _value Number of tokens to `transferFrom`.\n@return True if the approval succeeded.",
|
|
"id": 1359,
|
|
"implemented": true,
|
|
"isConstructor": false,
|
|
"isDeclaredConst": false,
|
|
"modifiers": [],
|
|
"name": "approve",
|
|
"nodeType": "FunctionDefinition",
|
|
"parameters": {
|
|
"id": 1336,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1333,
|
|
"name": "_spender",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1359,
|
|
"src": "3236:16:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1332,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3236:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1335,
|
|
"name": "_value",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1359,
|
|
"src": "3254:11:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 1334,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3254:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "3235:31:1"
|
|
},
|
|
"payable": false,
|
|
"returnParameters": {
|
|
"id": 1339,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1338,
|
|
"name": "success",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1359,
|
|
"src": "3299:12:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"typeName": {
|
|
"id": 1337,
|
|
"name": "bool",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3299:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "3298:14:1"
|
|
},
|
|
"scope": 1376,
|
|
"src": "3219:222:1",
|
|
"stateMutability": "nonpayable",
|
|
"superFunction": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 1374,
|
|
"nodeType": "Block",
|
|
"src": "3893:49:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1368,
|
|
"name": "allowed",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1168,
|
|
"src": "3910:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$",
|
|
"typeString": "mapping(address => mapping(address => uint256))"
|
|
}
|
|
},
|
|
"id": 1370,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1369,
|
|
"name": "_owner",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1361,
|
|
"src": "3918:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "3910:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_mapping$_t_address_$_t_uint256_$",
|
|
"typeString": "mapping(address => uint256)"
|
|
}
|
|
},
|
|
"id": 1372,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 1371,
|
|
"name": "_spender",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1363,
|
|
"src": "3926:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "3910:25:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"functionReturnParameters": 1367,
|
|
"id": 1373,
|
|
"nodeType": "Return",
|
|
"src": "3903:32:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": "Gets the number of tokens that an `_owner` has approved for a _spender\n to `transferFrom`.\n@param _owner Wallet address that tokens can be withdrawn from.\n@param _spender Wallet address that tokens can be deposited to.\n@return The number of tokens allowed to be transferred.",
|
|
"id": 1375,
|
|
"implemented": true,
|
|
"isConstructor": false,
|
|
"isDeclaredConst": true,
|
|
"modifiers": [],
|
|
"name": "allowance",
|
|
"nodeType": "FunctionDefinition",
|
|
"parameters": {
|
|
"id": 1364,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1361,
|
|
"name": "_owner",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1375,
|
|
"src": "3794:14:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1360,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3794:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 1363,
|
|
"name": "_spender",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1375,
|
|
"src": "3810:16:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 1362,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3810:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "3793:34:1"
|
|
},
|
|
"payable": false,
|
|
"returnParameters": {
|
|
"id": 1367,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1366,
|
|
"name": "remaining",
|
|
"nodeType": "VariableDeclaration",
|
|
"scope": 1375,
|
|
"src": "3873:14:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 1365,
|
|
"name": "uint",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3873:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "3872:16:1"
|
|
},
|
|
"scope": 1376,
|
|
"src": "3775:167:1",
|
|
"stateMutability": "view",
|
|
"superFunction": null,
|
|
"visibility": "public"
|
|
}
|
|
],
|
|
"scope": 1377,
|
|
"src": "169:3775:1"
|
|
}
|
|
],
|
|
"src": "0:3944:1"
|
|
},
|
|
"compiler": {
|
|
"name": "solc",
|
|
"version": "0.4.24+commit.e67f0147.Emscripten.clang"
|
|
},
|
|
"networks": {},
|
|
"schemaVersion": "2.0.0",
|
|
"updatedAt": "2018-06-27T15:13:50.245Z"
|
|
} |