{ "contractName": "EtherToken", "abi": [ { "inputs": [ { "internalType": "string", "name": "_name", "type": "string" }, { "internalType": "string", "name": "_symbol", "type": "string" } ], "stateMutability": "nonpayable", "type": "constructor" }, { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "address", "name": "_owner", "type": "address" }, { "indexed": true, "internalType": "address", "name": "_spender", "type": "address" }, { "indexed": false, "internalType": "uint256", "name": "_value", "type": "uint256" } ], "name": "Approval", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "_amount", "type": "uint256" } ], "name": "Destruction", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "_amount", "type": "uint256" } ], "name": "Issuance", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "address", "name": "_from", "type": "address" }, { "indexed": true, "internalType": "address", "name": "_to", "type": "address" }, { "indexed": false, "internalType": "uint256", "name": "_value", "type": "uint256" } ], "name": "Transfer", "type": "event" }, { "inputs": [ { "internalType": "address", "name": "", "type": "address" }, { "internalType": "address", "name": "", "type": "address" } ], "name": "allowance", "outputs": [ { "internalType": "uint256", "name": "", "type": "uint256" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "_spender", "type": "address" }, { "internalType": "uint256", "name": "_value", "type": "uint256" } ], "name": "approve", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "", "type": "address" } ], "name": "balanceOf", "outputs": [ { "internalType": "uint256", "name": "", "type": "uint256" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "decimals", "outputs": [ { "internalType": "uint8", "name": "", "type": "uint8" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "name", "outputs": [ { "internalType": "string", "name": "", "type": "string" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "symbol", "outputs": [ { "internalType": "string", "name": "", "type": "string" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "totalSupply", "outputs": [ { "internalType": "uint256", "name": "", "type": "uint256" } ], "stateMutability": "view", "type": "function" }, { "stateMutability": "payable", "type": "receive" }, { "inputs": [], "name": "deposit", "outputs": [], "stateMutability": "payable", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "_amount", "type": "uint256" } ], "name": "withdraw", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "_to", "type": "address" } ], "name": "depositTo", "outputs": [], "stateMutability": "payable", "type": "function" }, { "inputs": [ { "internalType": "address payable", "name": "_to", "type": "address" }, { "internalType": "uint256", "name": "_amount", "type": "uint256" } ], "name": "withdrawTo", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "_to", "type": "address" }, { "internalType": "uint256", "name": "_value", "type": "uint256" } ], "name": "transfer", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "_from", "type": "address" }, { "internalType": "address", "name": "_to", "type": "address" }, { "internalType": "uint256", "name": "_value", "type": "uint256" } ], "name": "transferFrom", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "stateMutability": "nonpayable", "type": "function" } ], "metadata": "{\"compiler\":{\"version\":\"0.6.12+commit.27d51765\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"string\",\"name\":\"_name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"_symbol\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"_owner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"_spender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"Destruction\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"Issuance\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"deposit\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"}],\"name\":\"depositTo\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"withdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address payable\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"withdrawTo\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}],\"devdoc\":{\"details\":\"Ether tokenization contract 'Owned' is specified here for readability reasons\",\"events\":{\"Destruction(uint256)\":{\"details\":\"triggered when the total supply is decreased\",\"params\":{\"_amount\":\"amount that gets removed from the supply\"}},\"Issuance(uint256)\":{\"details\":\"triggered when the total supply is increased\",\"params\":{\"_amount\":\"amount that gets added to the supply\"}}},\"kind\":\"dev\",\"methods\":{\"approve(address,uint256)\":{\"details\":\"allows another account/contract to transfers tokens on behalf of the caller throws on any error rather then return a false flag to minimize user errors also, to minimize the risk of the approve/transferFrom attack vector (see https://docs.google.com/document/d/1YLPtQxZu1UAvO9cZ1O2RPXBbT0mooh4DYKjA_jp-RLM/), approve has to be called twice in 2 separate transactions - once to change the allowance to 0 and secondly to change it to the new allowance value\",\"params\":{\"_spender\":\"approved address\",\"_value\":\"allowance amount\"},\"returns\":{\"_0\":\"true if the approval was successful, false if it wasn't\"}},\"constructor\":{\"details\":\"initializes a new EtherToken instance\",\"params\":{\"_name\":\"token name\",\"_symbol\":\"token symbol\"}},\"deposit()\":{\"details\":\"deposit ether on behalf of the sender\"},\"depositTo(address)\":{\"details\":\"deposit ether to be entitled for a given account\",\"params\":{\"_to\":\"account to be entitled for the ether\"}},\"transfer(address,uint256)\":{\"details\":\"send coins throws on any error rather then return a false flag to minimize user errors\",\"params\":{\"_to\":\"target address\",\"_value\":\"transfer amount\"},\"returns\":{\"_0\":\"true if the transfer was successful, false if it wasn't\"}},\"transferFrom(address,address,uint256)\":{\"details\":\"an account/contract attempts to get the coins throws on any error rather then return a false flag to minimize user errors\",\"params\":{\"_from\":\"source address\",\"_to\":\"target address\",\"_value\":\"transfer amount\"},\"returns\":{\"_0\":\"true if the transfer was successful, false if it wasn't\"}},\"withdraw(uint256)\":{\"details\":\"withdraw ether to the sender's account\",\"params\":{\"_amount\":\"amount of ether to withdraw\"}},\"withdrawTo(address,uint256)\":{\"details\":\"withdraw ether entitled by the sender to a given account\",\"params\":{\"_amount\":\"amount of ether to withdraw\",\"_to\":\"account to receive the ether\"}}},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/EtherToken.sol\":\"EtherToken\"},\"evmVersion\":\"istanbul\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":200},\"remappings\":[]},\"sources\":{\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/ERC20Token.sol\":{\"keccak256\":\"0xf64a993754bb4afcdfda9e8fe377c2c8a198f23b39e954f5ee3f9f2825958ebd\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://9ee0b7fd792a589b8321f1f13686fe5d5ae949288b124c1a57e2ad895c87e915\",\"dweb:/ipfs/QmTCRx2G6rJAhX9FyYkV4Gx69owVDYSkjNGNFrJGQ7Xnik\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/EtherToken.sol\":{\"keccak256\":\"0x8c7f758cc26d6a2c9623cde478baf93b5de1ef66fe441b45cc006ed75738ca10\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://adcc6fdd76dabbbb77451742843251d34ceebdcbc8274513ee6c3b8419597b24\",\"dweb:/ipfs/QmWjf3NWqE7pDkFynN2MQfhyrsYdpdoU6vP5KM6FKQUtVq\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/interfaces/IERC20Token.sol\":{\"keccak256\":\"0xe6f988c3156e88258474526a541d5a42b6a9adae98b04177a059d9f723bc82cd\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://9a6eb77a5b9ce70995a11a6e48ac3985a4c70896fe5fe04d46146ad7c1c83ea3\",\"dweb:/ipfs/QmYvGSveZFG51tghwkVuu6eK9Jy8frHpfLxHTMyvNZN461\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/interfaces/IEtherToken.sol\":{\"keccak256\":\"0x6ed324da616d70af0b21fa073b1e5329b430e38b470177633a69710eff3da893\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://44f94aa59c67de636423cbdef82efb7d8e0562e73dfc9049a48054156aebaf14\",\"dweb:/ipfs/Qmdn8KAP54s7X3J6TCoZPhCpS19aCQzFYZuFABugJ5JA5D\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/SafeMath.sol\":{\"keccak256\":\"0x1ab7391a19ca8a3ad2f3c4a1074e080d4d76dfdb834637bdd0c1e6b6acdf28af\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://d6d8c99621ca884b72da2d84eddfec8ec8c5533915691d6eec94a07adf445608\",\"dweb:/ipfs/QmaXr6DN7VbfxfMn3PsTy7SAMgZVVXbdeaw11BsAjVL2x1\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/Utils.sol\":{\"keccak256\":\"0x073efa69fcd6b5e60f841b28b366d63b62ff48ab12a06ce3f5a7f41afd6ce885\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://e8b8ecb2d29197ca77f0ed98f728ace54e6edcfdf5cd1194ae22701607eaf608\",\"dweb:/ipfs/QmcsR6Q35Hurh3TrPkYAboicz9bQQoGCWmZLzUCDyhotH8\"]}},\"version\":1}", "bytecode": "0x60806040523480156200001157600080fd5b5060405162000e0738038062000e07833981810160405260408110156200003757600080fd5b81019080805160405193929190846401000000008211156200005857600080fd5b9083019060208201858111156200006e57600080fd5b82516401000000008111828201881017156200008957600080fd5b82525081516020918201929091019080838360005b83811015620000b85781810151838201526020016200009e565b50505050905090810190601f168015620000e65780820380516001836020036101000a031916815260200191505b50604052602001805160405193929190846401000000008211156200010a57600080fd5b9083019060208201858111156200012057600080fd5b82516401000000008111828201881017156200013b57600080fd5b82525081516020918201929091019080838360005b838110156200016a57818101518382015260200162000150565b50505050905090810190601f168015620001985780820380516001836020036101000a031916815260200191505b5060405250505081816012600080845111620001ee576040805162461bcd60e51b815260206004820152601060248201526f4552525f494e56414c49445f4e414d4560801b604482015290519081900360640190fd5b60008351116200023a576040805162461bcd60e51b815260206004820152601260248201527111549497d253959053125117d4d6535093d360721b604482015290519081900360640190fd5b83516200024f9060009060208701906200029b565b508251620002659060019060208601906200029b565b506002805460ff191660ff9390931692909217909155600381905533600090815260046020526040902055506200033792505050565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620002de57805160ff19168380011785556200030e565b828001600101855582156200030e579182015b828111156200030e578251825591602001919060010190620002f1565b506200031c92915062000320565b5090565b5b808211156200031c576000815560010162000321565b610ac080620003476000396000f3fe6080604052600436106100c65760003560e01c8063313ce5671161007f578063a9059cbb11610059578063a9059cbb146102f1578063b760faf91461032a578063d0e30db014610350578063dd62ed3e14610358576100d5565b8063313ce5671461027e57806370a08231146102a957806395d89b41146102dc576100d5565b806306fdde03146100da578063095ea7b31461016457806318160ddd146101b1578063205c2878146101d857806323b872dd146102115780632e1a7d4d14610254576100d5565b366100d5576100d3610393565b005b600080fd5b3480156100e657600080fd5b506100ef61039e565b6040805160208082528351818301528351919283929083019185019080838360005b83811015610129578181015183820152602001610111565b50505050905090810190601f1680156101565780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561017057600080fd5b5061019d6004803603604081101561018757600080fd5b506001600160a01b03813516906020013561042c565b604080519115158252519081900360200190f35b3480156101bd57600080fd5b506101c6610514565b60408051918252519081900360200190f35b3480156101e457600080fd5b506100d3600480360360408110156101fb57600080fd5b506001600160a01b03813516906020013561051a565b34801561021d57600080fd5b5061019d6004803603606081101561023457600080fd5b506001600160a01b038135811691602081013590911690604001356105f2565b34801561026057600080fd5b506100d36004803603602081101561027757600080fd5b5035610612565b34801561028a57600080fd5b5061029361061f565b6040805160ff9092168252519081900360200190f35b3480156102b557600080fd5b506101c6600480360360208110156102cc57600080fd5b50356001600160a01b0316610628565b3480156102e857600080fd5b506100ef61063a565b3480156102fd57600080fd5b5061019d6004803603604081101561031457600080fd5b506001600160a01b038135169060200135610694565b6100d36004803603602081101561034057600080fd5b50356001600160a01b03166106b2565b6100d3610393565b34801561036457600080fd5b506101c66004803603604081101561037b57600080fd5b506001600160a01b038135811691602001351661076d565b61039c336106b2565b565b6000805460408051602060026001851615610100026000190190941693909304601f810184900484028201840190925281815292918301828280156104245780601f106103f957610100808354040283529160200191610424565b820191906000526020600020905b81548152906001019060200180831161040757829003601f168201915b505050505081565b6000826104388161078a565b82158061046657503360009081526005602090815260408083206001600160a01b0388168452909152902054155b6104ac576040805162461bcd60e51b815260206004820152601260248201527111549497d253959053125117d05353d5539560721b604482015290519081900360640190fd5b3360008181526005602090815260408083206001600160a01b03891680855290835292819020879055805187815290519293927f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925929181900390910190a35060019392505050565b60035481565b81610524816107db565b3360009081526004602052604090205461053e908361082f565b3360009081526004602052604090205560035461055b908361082f565b6003556040516001600160a01b0384169083156108fc029084906000818181858888f19350505050158015610594573d6000803e3d6000fd5b5060408051838152905130913391600080516020610a6b8339815191529181900360200190a36040805183815290517f9a1b418bc061a5d80270261562e6986a35d995f8051145f277be16103abd34539181900360200190a1505050565b6000826105fe816107db565b61060985858561087c565b95945050505050565b61061c338261051a565b50565b60025460ff1681565b60046020526000908152604090205481565b60018054604080516020600284861615610100026000190190941693909304601f810184900484028201840190925281815292918301828280156104245780601f106103f957610100808354040283529160200191610424565b6000826106a0816107db565b6106aa848461097b565b949350505050565b806106bc816107db565b6001600160a01b0382166000908152600460205260409020546106df9034610a1a565b6001600160a01b0383166000908152600460205260409020556003546107059034610a1a565b6003556040805134815290517f9386c90217c323f58030f9dadcbc938f807a940f4ff41cd4cead9562f5da7dc39181900360200190a16040805134815290516001600160a01b038416913091600080516020610a6b8339815191529181900360200190a35050565b600560209081526000928352604080842090915290825290205481565b6001600160a01b03811661061c576040805162461bcd60e51b81526020600482015260136024820152724552525f494e56414c49445f4144445245535360681b604482015290519081900360640190fd5b6001600160a01b03811630141561061c576040805162461bcd60e51b815260206004820152601360248201527222a9292fa0a2222922a9a9afa4a9afa9a2a62360691b604482015290519081900360640190fd5b600081831015610876576040805162461bcd60e51b815260206004820152600d60248201526c4552525f554e444552464c4f5760981b604482015290519081900360640190fd5b50900390565b6000836108888161078a565b836108928161078a565b6001600160a01b03861660009081526005602090815260408083203384529091529020546108c0908561082f565b6001600160a01b0387166000818152600560209081526040808320338452825280832094909455918152600490915220546108fb908561082f565b6001600160a01b03808816600090815260046020526040808220939093559087168152205461092a9085610a1a565b6001600160a01b0380871660008181526004602090815260409182902094909455805188815290519193928a1692600080516020610a6b83398151915292918290030190a350600195945050505050565b6000826109878161078a565b336000908152600460205260409020546109a1908461082f565b33600090815260046020526040808220929092556001600160a01b038616815220546109cd9084610a1a565b6001600160a01b038516600081815260046020908152604091829020939093558051868152905191923392600080516020610a6b8339815191529281900390910190a35060019392505050565b600082820183811015610a63576040805162461bcd60e51b815260206004820152600c60248201526b4552525f4f564552464c4f5760a01b604482015290519081900360640190fd5b939250505056feddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa264697066735822122029c1e8ed4c9efa01a428c8f35f0d8c72b801cc0161065977203a80395ce1976664736f6c634300060c0033", "deployedBytecode": "0x6080604052600436106100c65760003560e01c8063313ce5671161007f578063a9059cbb11610059578063a9059cbb146102f1578063b760faf91461032a578063d0e30db014610350578063dd62ed3e14610358576100d5565b8063313ce5671461027e57806370a08231146102a957806395d89b41146102dc576100d5565b806306fdde03146100da578063095ea7b31461016457806318160ddd146101b1578063205c2878146101d857806323b872dd146102115780632e1a7d4d14610254576100d5565b366100d5576100d3610393565b005b600080fd5b3480156100e657600080fd5b506100ef61039e565b6040805160208082528351818301528351919283929083019185019080838360005b83811015610129578181015183820152602001610111565b50505050905090810190601f1680156101565780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561017057600080fd5b5061019d6004803603604081101561018757600080fd5b506001600160a01b03813516906020013561042c565b604080519115158252519081900360200190f35b3480156101bd57600080fd5b506101c6610514565b60408051918252519081900360200190f35b3480156101e457600080fd5b506100d3600480360360408110156101fb57600080fd5b506001600160a01b03813516906020013561051a565b34801561021d57600080fd5b5061019d6004803603606081101561023457600080fd5b506001600160a01b038135811691602081013590911690604001356105f2565b34801561026057600080fd5b506100d36004803603602081101561027757600080fd5b5035610612565b34801561028a57600080fd5b5061029361061f565b6040805160ff9092168252519081900360200190f35b3480156102b557600080fd5b506101c6600480360360208110156102cc57600080fd5b50356001600160a01b0316610628565b3480156102e857600080fd5b506100ef61063a565b3480156102fd57600080fd5b5061019d6004803603604081101561031457600080fd5b506001600160a01b038135169060200135610694565b6100d36004803603602081101561034057600080fd5b50356001600160a01b03166106b2565b6100d3610393565b34801561036457600080fd5b506101c66004803603604081101561037b57600080fd5b506001600160a01b038135811691602001351661076d565b61039c336106b2565b565b6000805460408051602060026001851615610100026000190190941693909304601f810184900484028201840190925281815292918301828280156104245780601f106103f957610100808354040283529160200191610424565b820191906000526020600020905b81548152906001019060200180831161040757829003601f168201915b505050505081565b6000826104388161078a565b82158061046657503360009081526005602090815260408083206001600160a01b0388168452909152902054155b6104ac576040805162461bcd60e51b815260206004820152601260248201527111549497d253959053125117d05353d5539560721b604482015290519081900360640190fd5b3360008181526005602090815260408083206001600160a01b03891680855290835292819020879055805187815290519293927f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925929181900390910190a35060019392505050565b60035481565b81610524816107db565b3360009081526004602052604090205461053e908361082f565b3360009081526004602052604090205560035461055b908361082f565b6003556040516001600160a01b0384169083156108fc029084906000818181858888f19350505050158015610594573d6000803e3d6000fd5b5060408051838152905130913391600080516020610a6b8339815191529181900360200190a36040805183815290517f9a1b418bc061a5d80270261562e6986a35d995f8051145f277be16103abd34539181900360200190a1505050565b6000826105fe816107db565b61060985858561087c565b95945050505050565b61061c338261051a565b50565b60025460ff1681565b60046020526000908152604090205481565b60018054604080516020600284861615610100026000190190941693909304601f810184900484028201840190925281815292918301828280156104245780601f106103f957610100808354040283529160200191610424565b6000826106a0816107db565b6106aa848461097b565b949350505050565b806106bc816107db565b6001600160a01b0382166000908152600460205260409020546106df9034610a1a565b6001600160a01b0383166000908152600460205260409020556003546107059034610a1a565b6003556040805134815290517f9386c90217c323f58030f9dadcbc938f807a940f4ff41cd4cead9562f5da7dc39181900360200190a16040805134815290516001600160a01b038416913091600080516020610a6b8339815191529181900360200190a35050565b600560209081526000928352604080842090915290825290205481565b6001600160a01b03811661061c576040805162461bcd60e51b81526020600482015260136024820152724552525f494e56414c49445f4144445245535360681b604482015290519081900360640190fd5b6001600160a01b03811630141561061c576040805162461bcd60e51b815260206004820152601360248201527222a9292fa0a2222922a9a9afa4a9afa9a2a62360691b604482015290519081900360640190fd5b600081831015610876576040805162461bcd60e51b815260206004820152600d60248201526c4552525f554e444552464c4f5760981b604482015290519081900360640190fd5b50900390565b6000836108888161078a565b836108928161078a565b6001600160a01b03861660009081526005602090815260408083203384529091529020546108c0908561082f565b6001600160a01b0387166000818152600560209081526040808320338452825280832094909455918152600490915220546108fb908561082f565b6001600160a01b03808816600090815260046020526040808220939093559087168152205461092a9085610a1a565b6001600160a01b0380871660008181526004602090815260409182902094909455805188815290519193928a1692600080516020610a6b83398151915292918290030190a350600195945050505050565b6000826109878161078a565b336000908152600460205260409020546109a1908461082f565b33600090815260046020526040808220929092556001600160a01b038616815220546109cd9084610a1a565b6001600160a01b038516600081815260046020908152604091829020939093558051868152905191923392600080516020610a6b8339815191529281900390910190a35060019392505050565b600082820183811015610a63576040805162461bcd60e51b815260206004820152600c60248201526b4552525f4f564552464c4f5760a01b604482015290519081900360640190fd5b939250505056feddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa264697066735822122029c1e8ed4c9efa01a428c8f35f0d8c72b801cc0161065977203a80395ce1976664736f6c634300060c0033", "immutableReferences": {}, "sourceMap": "289:3737:49:-:0;;;919:123;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;919:123:49;;;;;;;;;;-1:-1:-1;919:123:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;919:123:49;;;;;;;;;;-1:-1:-1;919:123:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1011:5;1018:7;1027:2;1031:1;1747::48;1731:5;1725:19;:23;1717:52;;;;;-1:-1:-1;;;1717:52:48;;;;;;;;;;;;-1:-1:-1;;;1717:52:48;;;;;;;;;;;;;;;1812:1;1794:7;1788:21;:25;1780:56;;;;;-1:-1:-1;;;1780:56:48;;;;;;;;;;;;-1:-1:-1;;;1780:56:48;;;;;;;;;;;;;;;1849:12;;;;:4;;:12;;;;;:::i;:::-;-1:-1:-1;1872:16:48;;;;:6;;:16;;;;;:::i;:::-;-1:-1:-1;1899:8:48;:20;;-1:-1:-1;;1899:20:48;;;;;;;;;;;;;1930:11;:26;;;1977:10;-1:-1:-1;1967:21:48;;;:9;:21;;;;;:36;-1:-1:-1;289:3737:49;;-1:-1:-1;;;289:3737:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;289:3737:49;;;-1:-1:-1;289:3737:49;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;", "deployedSourceMap": "289:3737:49:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4006:9;:7;:9::i;:::-;289:3737;;;;;327:27:48;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4284:519;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;4284:519:48;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;434:35;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;2201:491:49;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;2201:491:49;;;;;;;;:::i;3660:240::-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;3660:240:49;;;;;;;;;;;;;;;;;:::i;1342:101::-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;1342:101:49;;:::i;397:30:48:-;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;476:54;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;476:54:48;-1:-1:-1;;;;;476:54:48;;:::i;361:29::-;;;;;;;;;;;;;:::i;3068:210:49:-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;3068:210:49;;;;;;;;:::i;1602:387::-;;;;;;;;;;;;;;;;-1:-1:-1;1602:387:49;-1:-1:-1;;;;;1602:387:49;;:::i;1119:83::-;;;:::i;537:75:48:-;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;537:75:48;;;;;;;;;;:::i;1119:83:49:-;1173:21;1183:10;1173:9;:21::i;:::-;1119:83::o;327:27:48:-;;;;;;;;;;;;;;;-1:-1:-1;;327:27:48;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;4284:519::-;4436:4;4408:8;594:23:65;608:8;594:13;:23::i;:::-;4592:11:48;;;:51:::1;;-1:-1:-1::0;4617:10:48::1;4607:21;::::0;;;:9:::1;:21;::::0;;;;;;;-1:-1:-1;;;;;4607:31:48;::::1;::::0;;;;;;;;:36;4592:51:::1;4584:82;;;::::0;;-1:-1:-1;;;4584:82:48;;::::1;;::::0;::::1;::::0;::::1;::::0;;;;-1:-1:-1;;;4584:82:48;;;;;;;;;;;;;::::1;;4689:10;4679:21;::::0;;;:9:::1;:21;::::0;;;;;;;-1:-1:-1;;;;;4679:31:48;::::1;::::0;;;;;;;;;;:40;;;4735:38;;;;;;;4679:31;;4689:10;4735:38:::1;::::0;;;;;;;;;::::1;-1:-1:-1::0;4791:4:48::1;::::0;4284:519;-1:-1:-1;;;4284:519:48:o;434:35::-;;;;:::o;2201:491:49:-;2310:3;948:18:65;957:8;948;:18::i;:::-;2365:10:49::1;2355:21;::::0;;;:9:::1;:21;::::0;;;;;:34:::1;::::0;2381:7;2355:25:::1;:34::i;:::-;2341:10;2331:21;::::0;;;:9:::1;:21;::::0;;;;:58;2460:11:::1;::::0;:24:::1;::::0;2476:7;2460:15:::1;:24::i;:::-;2446:11;:38:::0;2524:21:::1;::::0;-1:-1:-1;;;;;2524:12:49;::::1;::::0;:21;::::1;;;::::0;2537:7;;2524:21:::1;::::0;;;2537:7;2524:12;:21;::::1;;;;;;;;;;;;;::::0;::::1;;;;;-1:-1:-1::0;2604:44:49::1;::::0;;;;;;;2633:4:::1;::::0;2613:10:::1;::::0;-1:-1:-1;;;;;;;;;;;2604:44:49;;;;::::1;::::0;;::::1;2664:20;::::0;;;;;;;::::1;::::0;;;;::::1;::::0;;::::1;2201:491:::0;;;:::o;3660:240::-;3825:4;3802:3;948:18:65;957:8;948;:18::i;:::-;3854:38:49::1;3873:5;3880:3;3885:6;3854:18;:38::i;:::-;3847:45:::0;3660:240;-1:-1:-1;;;;;3660:240:49:o;1342:101::-;1404:31;1415:10;1427:7;1404:10;:31::i;:::-;1342:101;:::o;397:30:48:-;;;;;;:::o;476:54::-;;;;;;;;;;;;;:::o;361:29::-;;;;;;;;;;;;;;;-1:-1:-1;;361:29:48;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3068:210:49;3214:4;3191:3;948:18:65;957:8;948;:18::i;:::-;3243:27:49::1;3258:3;3263:6;3243:14;:27::i;:::-;3236:34:::0;3068:210;-1:-1:-1;;;;3068:210:49:o;1602:387::-;1702:3;948:18:65;957:8;948;:18::i;:::-;-1:-1:-1;;;;;1740:14:49;::::1;;::::0;;;:9:::1;:14;::::0;;;;;:29:::1;::::0;1759:9:::1;1740:18;:29::i;:::-;-1:-1:-1::0;;;;;1723:14:49;::::1;;::::0;;;:9:::1;:14;::::0;;;;:46;1834:11:::1;::::0;:26:::1;::::0;1850:9:::1;1834:15;:26::i;:::-;1820:11;:40:::0;1907:19:::1;::::0;;1916:9:::1;1907:19:::0;;;;::::1;::::0;;;;::::1;::::0;;::::1;1942:39;::::0;;1971:9:::1;1942:39:::0;;;;-1:-1:-1;;;;;1942:39:49;::::1;::::0;1959:4:::1;::::0;-1:-1:-1;;;;;;;;;;;1942:39:49;;;;::::1;::::0;;::::1;1602:387:::0;;:::o;537:75:48:-;;;;;;;;;;;;;;;;;;;;;;;;:::o;692:128:65:-;-1:-1:-1;;;;;766:22:65;;758:54;;;;;-1:-1:-1;;;758:54:65;;;;;;;;;;;;-1:-1:-1;;;758:54:65;;;;;;;;;;;;;;1041:126;-1:-1:-1;;;;;1110:25:65;;1130:4;1110:25;;1102:57;;;;;-1:-1:-1;;;1102:57:65;;;;;;;;;;;;-1:-1:-1;;;1102:57:65;;;;;;;;;;;;;;778:147:61;838:7;872:2;866;:8;;858:34;;;;;-1:-1:-1;;;858:34:61;;;;;;;;;;;;-1:-1:-1;;;858:34:61;;;;;;;;;;;;;;;-1:-1:-1;910:7:61;;;778:147::o;3099:470:48:-;3290:4;3238:5;594:23:65;608:8;594:13;:23::i;:::-;3267:3:48::1;594:23:65;608:8;594:13;:23::i;:::-;-1:-1:-1::0;;;;;3343:16:48;::::2;;::::0;;;:9:::2;:16;::::0;;;;;;;3360:10:::2;3343:28:::0;;;;;;;;:40:::2;::::0;3376:6;3343:32:::2;:40::i;:::-;-1:-1:-1::0;;;;;3312:16:48;::::2;;::::0;;;:9:::2;:16;::::0;;;;;;;3329:10:::2;3312:28:::0;;;;;;;:71;;;;3413:16;;;:9:::2;:16:::0;;;;;:28:::2;::::0;3434:6;3413:20:::2;:28::i;:::-;-1:-1:-1::0;;;;;3394:16:48;;::::2;;::::0;;;:9:::2;:16;::::0;;;;;:47;;;;3469:14;;::::2;::::0;;;;:26:::2;::::0;3488:6;3469:18:::2;:26::i;:::-;-1:-1:-1::0;;;;;3452:14:48;;::::2;;::::0;;;:9:::2;:14;::::0;;;;;;;;:43;;;;3511:28;;;;;;;3452:14;;3511:28;;::::2;::::0;-1:-1:-1;;;;;;;;;;;3511:28:48;;;;;;;::::2;-1:-1:-1::0;3557:4:48::2;::::0;3099:470;-1:-1:-1;;;;;3099:470:48:o;2343:355::-;2486:4;2463:3;594:23:65;608:8;594:13;:23::i;:::-;2542:10:48::1;2532:21;::::0;;;:9:::1;:21;::::0;;;;;:33:::1;::::0;2558:6;2532:25:::1;:33::i;:::-;2518:10;2508:21;::::0;;;:9:::1;:21;::::0;;;;;:57;;;;-1:-1:-1;;;;;2593:14:48;::::1;::::0;;;;:26:::1;::::0;2612:6;2593:18:::1;:26::i;:::-;-1:-1:-1::0;;;;;2576:14:48;::::1;;::::0;;;:9:::1;:14;::::0;;;;;;;;:43;;;;2635:33;;;;;;;2576:14;;2644:10:::1;::::0;-1:-1:-1;;;;;;;;;;;2635:33:48;;;;;;;;::::1;-1:-1:-1::0;2686:4:48::1;::::0;2343:355;-1:-1:-1;;;2343:355:48:o;386:169:61:-;446:7;478;;;504;;;;496:32;;;;;-1:-1:-1;;;496:32:61;;;;;;;;;;;;-1:-1:-1;;;496:32:61;;;;;;;;;;;;;;;546:1;386:169;-1:-1:-1;;;386:169:61:o", "source": "// SPDX-License-Identifier: SEE LICENSE IN LICENSE\r\npragma solidity 0.6.12;\r\nimport \"./ERC20Token.sol\";\r\nimport \"./interfaces/IEtherToken.sol\";\r\nimport \"../utility/SafeMath.sol\";\r\n\r\n/**\r\n * @dev Ether tokenization contract\r\n *\r\n * 'Owned' is specified here for readability reasons\r\n*/\r\ncontract EtherToken is IEtherToken, ERC20Token {\r\n using SafeMath for uint256;\r\n\r\n /**\r\n * @dev triggered when the total supply is increased\r\n *\r\n * @param _amount amount that gets added to the supply\r\n */\r\n event Issuance(uint256 _amount);\r\n\r\n /**\r\n * @dev triggered when the total supply is decreased\r\n *\r\n * @param _amount amount that gets removed from the supply\r\n */\r\n event Destruction(uint256 _amount);\r\n\r\n /**\r\n * @dev initializes a new EtherToken instance\r\n *\r\n * @param _name token name\r\n * @param _symbol token symbol\r\n */\r\n constructor(string memory _name, string memory _symbol)\r\n public\r\n ERC20Token(_name, _symbol, 18, 0) {\r\n }\r\n\r\n /**\r\n * @dev deposit ether on behalf of the sender\r\n */\r\n function deposit() public override payable {\r\n depositTo(msg.sender);\r\n }\r\n\r\n /**\r\n * @dev withdraw ether to the sender's account\r\n *\r\n * @param _amount amount of ether to withdraw\r\n */\r\n function withdraw(uint256 _amount) public override {\r\n withdrawTo(msg.sender, _amount);\r\n }\r\n\r\n /**\r\n * @dev deposit ether to be entitled for a given account\r\n *\r\n * @param _to account to be entitled for the ether\r\n */\r\n function depositTo(address _to)\r\n public\r\n override\r\n payable\r\n notThis(_to)\r\n {\r\n balanceOf[_to] = balanceOf[_to].add(msg.value); // add the value to the account balance\r\n totalSupply = totalSupply.add(msg.value); // increase the total supply\r\n\r\n emit Issuance(msg.value);\r\n emit Transfer(address(this), _to, msg.value);\r\n }\r\n\r\n /**\r\n * @dev withdraw ether entitled by the sender to a given account\r\n *\r\n * @param _to account to receive the ether\r\n * @param _amount amount of ether to withdraw\r\n */\r\n function withdrawTo(address payable _to, uint256 _amount)\r\n public\r\n override\r\n notThis(_to)\r\n {\r\n balanceOf[msg.sender] = balanceOf[msg.sender].sub(_amount); // deduct the amount from the account balance\r\n totalSupply = totalSupply.sub(_amount); // decrease the total supply\r\n _to.transfer(_amount); // send the amount to the target account\r\n\r\n emit Transfer(msg.sender, address(this), _amount);\r\n emit Destruction(_amount);\r\n }\r\n\r\n // ERC20 standard method overrides with some extra protection\r\n\r\n /**\r\n * @dev send coins\r\n * throws on any error rather then return a false flag to minimize user errors\r\n *\r\n * @param _to target address\r\n * @param _value transfer amount\r\n *\r\n * @return true if the transfer was successful, false if it wasn't\r\n */\r\n function transfer(address _to, uint256 _value)\r\n public\r\n override(IERC20Token, ERC20Token)\r\n notThis(_to)\r\n returns (bool)\r\n {\r\n return super.transfer(_to, _value);\r\n }\r\n\r\n /**\r\n * @dev an account/contract attempts to get the coins\r\n * throws on any error rather then return a false flag to minimize user errors\r\n *\r\n * @param _from source address\r\n * @param _to target address\r\n * @param _value transfer amount\r\n *\r\n * @return true if the transfer was successful, false if it wasn't\r\n */\r\n function transferFrom(address _from, address _to, uint256 _value)\r\n public\r\n override(IERC20Token, ERC20Token)\r\n notThis(_to)\r\n returns (bool)\r\n {\r\n return super.transferFrom(_from, _to, _value);\r\n }\r\n\r\n /**\r\n * @dev deposit ether in the account\r\n */\r\n receive() external payable {\r\n deposit();\r\n }\r\n}\r\n", "sourcePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/EtherToken.sol", "ast": { "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/EtherToken.sol", "exportedSymbols": { "EtherToken": [ 20837 ] }, "id": 20838, "license": "SEE LICENSE IN LICENSE", "nodeType": "SourceUnit", "nodes": [ { "id": 20619, "literals": [ "solidity", "0.6", ".12" ], "nodeType": "PragmaDirective", "src": "52:23:49" }, { "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/ERC20Token.sol", "file": "./ERC20Token.sol", "id": 20620, "nodeType": "ImportDirective", "scope": 20838, "sourceUnit": 20618, "src": "77:26:49", "symbolAliases": [], "unitAlias": "" }, { "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/interfaces/IEtherToken.sol", "file": "./interfaces/IEtherToken.sol", "id": 20621, "nodeType": "ImportDirective", "scope": 20838, "sourceUnit": 21489, "src": "105:38:49", "symbolAliases": [], "unitAlias": "" }, { "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/SafeMath.sol", "file": "../utility/SafeMath.sol", "id": 20622, "nodeType": "ImportDirective", "scope": 20838, "sourceUnit": 22690, "src": "145:33:49", "symbolAliases": [], "unitAlias": "" }, { "abstract": false, "baseContracts": [ { "arguments": null, "baseName": { "contractScope": null, "id": 20624, "name": "IEtherToken", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 21488, "src": "312:11:49", "typeDescriptions": { "typeIdentifier": "t_contract$_IEtherToken_$21488", "typeString": "contract IEtherToken" } }, "id": 20625, "nodeType": "InheritanceSpecifier", "src": "312:11:49" }, { "arguments": null, "baseName": { "contractScope": null, "id": 20626, "name": "ERC20Token", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 20617, "src": "325:10:49", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$20617", "typeString": "contract ERC20Token" } }, "id": 20627, "nodeType": "InheritanceSpecifier", "src": "325:10:49" } ], "contractDependencies": [ 20617, 21462, 21488, 22996 ], "contractKind": "contract", "documentation": { "id": 20623, "nodeType": "StructuredDocumentation", "src": "182:105:49", "text": " @dev Ether tokenization contract\n 'Owned' is specified here for readability reasons" }, "fullyImplemented": true, "id": 20837, "linearizedBaseContracts": [ 20837, 20617, 22996, 21488, 21462 ], "name": "EtherToken", "nodeType": "ContractDefinition", "nodes": [ { "id": 20630, "libraryName": { "contractScope": null, "id": 20628, "name": "SafeMath", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 22689, "src": "349:8:49", "typeDescriptions": { "typeIdentifier": "t_contract$_SafeMath_$22689", "typeString": "library SafeMath" } }, "nodeType": "UsingForDirective", "src": "343:27:49", "typeName": { "id": 20629, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "362:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } }, { "anonymous": false, "documentation": { "id": 20631, "nodeType": "StructuredDocumentation", "src": "378:141:49", "text": " @dev triggered when the total supply is increased\n @param _amount amount that gets added to the supply" }, "id": 20635, "name": "Issuance", "nodeType": "EventDefinition", "parameters": { "id": 20634, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20633, "indexed": false, "mutability": "mutable", "name": "_amount", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20635, "src": "540:15:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 20632, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "540:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "539:17:49" }, "src": "525:32:49" }, { "anonymous": false, "documentation": { "id": 20636, "nodeType": "StructuredDocumentation", "src": "565:145:49", "text": " @dev triggered when the total supply is decreased\n @param _amount amount that gets removed from the supply" }, "id": 20640, "name": "Destruction", "nodeType": "EventDefinition", "parameters": { "id": 20639, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20638, "indexed": false, "mutability": "mutable", "name": "_amount", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20640, "src": "734:15:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 20637, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "734:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "733:17:49" }, "src": "716:35:49" }, { "body": { "id": 20654, "nodeType": "Block", "src": "1034:8:49", "statements": [] }, "documentation": { "id": 20641, "nodeType": "StructuredDocumentation", "src": "759:154:49", "text": " @dev initializes a new EtherToken instance\n @param _name token name\n @param _symbol token symbol" }, "id": 20655, "implemented": true, "kind": "constructor", "modifiers": [ { "arguments": [ { "argumentTypes": null, "id": 20648, "name": "_name", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20643, "src": "1011:5:49", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string memory" } }, { "argumentTypes": null, "id": 20649, "name": "_symbol", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20645, "src": "1018:7:49", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string memory" } }, { "argumentTypes": null, "hexValue": "3138", "id": 20650, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", "src": "1027:2:49", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_18_by_1", "typeString": "int_const 18" }, "value": "18" }, { "argumentTypes": null, "hexValue": "30", "id": 20651, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", "src": "1031:1:49", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", "typeString": "int_const 0" }, "value": "0" } ], "id": 20652, "modifierName": { "argumentTypes": null, "id": 20647, "name": "ERC20Token", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20617, "src": "1000:10:49", "typeDescriptions": { "typeIdentifier": "t_type$_t_contract$_ERC20Token_$20617_$", "typeString": "type(contract ERC20Token)" } }, "nodeType": "ModifierInvocation", "src": "1000:33:49" } ], "name": "", "nodeType": "FunctionDefinition", "overrides": null, "parameters": { "id": 20646, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20643, "mutability": "mutable", "name": "_name", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20655, "src": "931:19:49", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string" }, "typeName": { "id": 20642, "name": "string", "nodeType": "ElementaryTypeName", "src": "931:6:49", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 20645, "mutability": "mutable", "name": "_symbol", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20655, "src": "952:21:49", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string" }, "typeName": { "id": 20644, "name": "string", "nodeType": "ElementaryTypeName", "src": "952:6:49", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "value": null, "visibility": "internal" } ], "src": "930:44:49" }, "returnParameters": { "id": 20653, "nodeType": "ParameterList", "parameters": [], "src": "1034:0:49" }, "scope": 20837, "src": "919:123:49", "stateMutability": "nonpayable", "virtual": false, "visibility": "public" }, { "baseFunctions": [ 21470 ], "body": { "id": 20665, "nodeType": "Block", "src": "1162:40:49", "statements": [ { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20661, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "1183:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20662, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1183:10:49", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address_payable", "typeString": "address payable" } ], "id": 20660, "name": "depositTo", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20726, "src": "1173:9:49", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$", "typeString": "function (address)" } }, "id": 20663, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1173:21:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 20664, "nodeType": "ExpressionStatement", "src": "1173:21:49" } ] }, "documentation": { "id": 20656, "nodeType": "StructuredDocumentation", "src": "1050:63:49", "text": " @dev deposit ether on behalf of the sender" }, "functionSelector": "d0e30db0", "id": 20666, "implemented": true, "kind": "function", "modifiers": [], "name": "deposit", "nodeType": "FunctionDefinition", "overrides": { "id": 20658, "nodeType": "OverrideSpecifier", "overrides": [], "src": "1145:8:49" }, "parameters": { "id": 20657, "nodeType": "ParameterList", "parameters": [], "src": "1135:2:49" }, "returnParameters": { "id": 20659, "nodeType": "ParameterList", "parameters": [], "src": "1162:0:49" }, "scope": 20837, "src": "1119:83:49", "stateMutability": "payable", "virtual": false, "visibility": "public" }, { "baseFunctions": [ 21475 ], "body": { "id": 20679, "nodeType": "Block", "src": "1393:50:49", "statements": [ { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20674, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "1415:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20675, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1415:10:49", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, { "argumentTypes": null, "id": 20676, "name": "_amount", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20669, "src": "1427:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address_payable", "typeString": "address payable" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "id": 20673, "name": "withdrawTo", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20779, "src": "1404:10:49", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_payable_$_t_uint256_$returns$__$", "typeString": "function (address payable,uint256)" } }, "id": 20677, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1404:31:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 20678, "nodeType": "ExpressionStatement", "src": "1404:31:49" } ] }, "documentation": { "id": 20667, "nodeType": "StructuredDocumentation", "src": "1210:126:49", "text": " @dev withdraw ether to the sender's account\n @param _amount amount of ether to withdraw" }, "functionSelector": "2e1a7d4d", "id": 20680, "implemented": true, "kind": "function", "modifiers": [], "name": "withdraw", "nodeType": "FunctionDefinition", "overrides": { "id": 20671, "nodeType": "OverrideSpecifier", "overrides": [], "src": "1384:8:49" }, "parameters": { "id": 20670, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20669, "mutability": "mutable", "name": "_amount", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20680, "src": "1360:15:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 20668, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "1360:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "1359:17:49" }, "returnParameters": { "id": 20672, "nodeType": "ParameterList", "parameters": [], "src": "1393:0:49" }, "scope": 20837, "src": "1342:101:49", "stateMutability": "nonpayable", "virtual": false, "visibility": "public" }, { "baseFunctions": [ 21480 ], "body": { "id": 20725, "nodeType": "Block", "src": "1712:277:49", "statements": [ { "expression": { "argumentTypes": null, "id": 20700, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 20690, "name": "balanceOf", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20369, "src": "1723:9:49", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, "id": 20692, "indexExpression": { "argumentTypes": null, "id": 20691, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20683, "src": "1733:3:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "nodeType": "IndexAccess", "src": "1723:14:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20697, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "1759:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20698, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1759:9:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 20693, "name": "balanceOf", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20369, "src": "1740:9:49", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, "id": 20695, "indexExpression": { "argumentTypes": null, "id": 20694, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20683, "src": "1750:3:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "1740:14:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 20696, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "add", "nodeType": "MemberAccess", "referencedDeclaration": 22606, "src": "1740:18:49", "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": 20699, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1740:29:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "src": "1723:46:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 20701, "nodeType": "ExpressionStatement", "src": "1723:46:49" }, { "expression": { "argumentTypes": null, "id": 20708, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "id": 20702, "name": "totalSupply", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20364, "src": "1820:11:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20705, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "1850:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20706, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1850:9:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "id": 20703, "name": "totalSupply", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20364, "src": "1834:11:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 20704, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "add", "nodeType": "MemberAccess", "referencedDeclaration": 22606, "src": "1834:15:49", "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": 20707, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1834:26:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "src": "1820:40:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 20709, "nodeType": "ExpressionStatement", "src": "1820:40:49" }, { "eventCall": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20711, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "1916:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20712, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1916:9:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "id": 20710, "name": "Issuance", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20635, "src": "1907:8:49", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_uint256_$returns$__$", "typeString": "function (uint256)" } }, "id": 20713, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1907:19:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 20714, "nodeType": "EmitStatement", "src": "1902:24:49" }, { "eventCall": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 20718, "name": "this", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -28, "src": "1959:4:49", "typeDescriptions": { "typeIdentifier": "t_contract$_EtherToken_$20837", "typeString": "contract EtherToken" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_contract$_EtherToken_$20837", "typeString": "contract EtherToken" } ], "id": 20717, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", "src": "1951:7:49", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": { "id": 20716, "name": "address", "nodeType": "ElementaryTypeName", "src": "1951:7:49", "typeDescriptions": { "typeIdentifier": null, "typeString": null } } }, "id": 20719, "isConstant": false, "isLValue": false, "isPure": false, "kind": "typeConversion", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1951:13:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, { "argumentTypes": null, "id": 20720, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20683, "src": "1966:3:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20721, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "1971:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20722, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1971:9:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address_payable", "typeString": "address payable" }, { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "id": 20715, "name": "Transfer", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20385, "src": "1942:8:49", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, "id": 20723, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1942:39:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 20724, "nodeType": "EmitStatement", "src": "1937:44:49" } ] }, "documentation": { "id": 20681, "nodeType": "StructuredDocumentation", "src": "1451:145:49", "text": " @dev deposit ether to be entitled for a given account\n @param _to account to be entitled for the ether" }, "functionSelector": "b760faf9", "id": 20726, "implemented": true, "kind": "function", "modifiers": [ { "arguments": [ { "argumentTypes": null, "id": 20687, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20683, "src": "1702:3:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } } ], "id": 20688, "modifierName": { "argumentTypes": null, "id": 20686, "name": "notThis", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 22979, "src": "1694:7:49", "typeDescriptions": { "typeIdentifier": "t_modifier$_t_address_$", "typeString": "modifier (address)" } }, "nodeType": "ModifierInvocation", "src": "1694:12:49" } ], "name": "depositTo", "nodeType": "FunctionDefinition", "overrides": { "id": 20685, "nodeType": "OverrideSpecifier", "overrides": [], "src": "1659:8:49" }, "parameters": { "id": 20684, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20683, "mutability": "mutable", "name": "_to", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20726, "src": "1621:11:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 20682, "name": "address", "nodeType": "ElementaryTypeName", "src": "1621:7:49", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" } ], "src": "1620:13:49" }, "returnParameters": { "id": 20689, "nodeType": "ParameterList", "parameters": [], "src": "1712:0:49" }, "scope": 20837, "src": "1602:387:49", "stateMutability": "payable", "virtual": false, "visibility": "public" }, { "baseFunctions": [ 21487 ], "body": { "id": 20778, "nodeType": "Block", "src": "2320:372:49", "statements": [ { "expression": { "argumentTypes": null, "id": 20749, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 20738, "name": "balanceOf", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20369, "src": "2331:9:49", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, "id": 20741, "indexExpression": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20739, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "2341:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20740, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "2341:10:49", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "nodeType": "IndexAccess", "src": "2331:21:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 20747, "name": "_amount", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20731, "src": "2381:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 20742, "name": "balanceOf", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20369, "src": "2355:9:49", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, "id": 20745, "indexExpression": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20743, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "2365:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20744, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "2365:10:49", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "2355:21:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 20746, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sub", "nodeType": "MemberAccess", "referencedDeclaration": 22628, "src": "2355:25:49", "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": 20748, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "2355:34:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "src": "2331:58:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 20750, "nodeType": "ExpressionStatement", "src": "2331:58:49" }, { "expression": { "argumentTypes": null, "id": 20756, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "id": 20751, "name": "totalSupply", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20364, "src": "2446:11:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 20754, "name": "_amount", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20731, "src": "2476:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "id": 20752, "name": "totalSupply", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20364, "src": "2460:11:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 20753, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sub", "nodeType": "MemberAccess", "referencedDeclaration": 22628, "src": "2460:15:49", "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": 20755, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "2460:24:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "src": "2446:38:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 20757, "nodeType": "ExpressionStatement", "src": "2446:38:49" }, { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 20761, "name": "_amount", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20731, "src": "2537:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "id": 20758, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20729, "src": "2524:3:49", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, "id": 20760, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "transfer", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "2524:12:49", "typeDescriptions": { "typeIdentifier": "t_function_transfer_nonpayable$_t_uint256_$returns$__$", "typeString": "function (uint256)" } }, "id": 20762, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "2524:21:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 20763, "nodeType": "ExpressionStatement", "src": "2524:21:49" }, { "eventCall": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20765, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "2613:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20766, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "2613:10:49", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 20769, "name": "this", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -28, "src": "2633:4:49", "typeDescriptions": { "typeIdentifier": "t_contract$_EtherToken_$20837", "typeString": "contract EtherToken" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_contract$_EtherToken_$20837", "typeString": "contract EtherToken" } ], "id": 20768, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", "src": "2625:7:49", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": { "id": 20767, "name": "address", "nodeType": "ElementaryTypeName", "src": "2625:7:49", "typeDescriptions": { "typeIdentifier": null, "typeString": null } } }, "id": 20770, "isConstant": false, "isLValue": false, "isPure": false, "kind": "typeConversion", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "2625:13:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, { "argumentTypes": null, "id": 20771, "name": "_amount", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20731, "src": "2640:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address_payable", "typeString": "address payable" }, { "typeIdentifier": "t_address_payable", "typeString": "address payable" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "id": 20764, "name": "Transfer", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20385, "src": "2604:8:49", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, "id": 20772, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "2604:44:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 20773, "nodeType": "EmitStatement", "src": "2599:49:49" }, { "eventCall": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 20775, "name": "_amount", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20731, "src": "2676:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "id": 20774, "name": "Destruction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20640, "src": "2664:11:49", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_uint256_$returns$__$", "typeString": "function (uint256)" } }, "id": 20776, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "2664:20:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 20777, "nodeType": "EmitStatement", "src": "2659:25:49" } ] }, "documentation": { "id": 20727, "nodeType": "StructuredDocumentation", "src": "1997:198:49", "text": " @dev withdraw ether entitled by the sender to a given account\n @param _to account to receive the ether\n @param _amount amount of ether to withdraw" }, "functionSelector": "205c2878", "id": 20779, "implemented": true, "kind": "function", "modifiers": [ { "arguments": [ { "argumentTypes": null, "id": 20735, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20729, "src": "2310:3:49", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } } ], "id": 20736, "modifierName": { "argumentTypes": null, "id": 20734, "name": "notThis", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 22979, "src": "2302:7:49", "typeDescriptions": { "typeIdentifier": "t_modifier$_t_address_$", "typeString": "modifier (address)" } }, "nodeType": "ModifierInvocation", "src": "2302:12:49" } ], "name": "withdrawTo", "nodeType": "FunctionDefinition", "overrides": { "id": 20733, "nodeType": "OverrideSpecifier", "overrides": [], "src": "2284:8:49" }, "parameters": { "id": 20732, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20729, "mutability": "mutable", "name": "_to", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20779, "src": "2221:19:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" }, "typeName": { "id": 20728, "name": "address", "nodeType": "ElementaryTypeName", "src": "2221:15:49", "stateMutability": "payable", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 20731, "mutability": "mutable", "name": "_amount", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20779, "src": "2242:15:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 20730, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "2242:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "2220:38:49" }, "returnParameters": { "id": 20737, "nodeType": "ParameterList", "parameters": [], "src": "2320:0:49" }, "scope": 20837, "src": "2201:491:49", "stateMutability": "nonpayable", "virtual": false, "visibility": "public" }, { "baseFunctions": [ 20500, 21441 ], "body": { "id": 20801, "nodeType": "Block", "src": "3225:53:49", "statements": [ { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 20797, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20782, "src": "3258:3:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 20798, "name": "_value", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20784, "src": "3263:6:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "id": 20795, "name": "super", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -25, "src": "3243:5:49", "typeDescriptions": { "typeIdentifier": "t_super$_EtherToken_$20837", "typeString": "contract super EtherToken" } }, "id": 20796, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "transfer", "nodeType": "MemberAccess", "referencedDeclaration": 20500, "src": "3243:14:49", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$", "typeString": "function (address,uint256) returns (bool)" } }, "id": 20799, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "3243:27:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "functionReturnParameters": 20794, "id": 20800, "nodeType": "Return", "src": "3236:34:49" } ] }, "documentation": { "id": 20780, "nodeType": "StructuredDocumentation", "src": "2769:293:49", "text": " @dev send coins\n throws on any error rather then return a false flag to minimize user errors\n @param _to target address\n @param _value transfer amount\n @return true if the transfer was successful, false if it wasn't" }, "functionSelector": "a9059cbb", "id": 20802, "implemented": true, "kind": "function", "modifiers": [ { "arguments": [ { "argumentTypes": null, "id": 20790, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20782, "src": "3191:3:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } } ], "id": 20791, "modifierName": { "argumentTypes": null, "id": 20789, "name": "notThis", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 22979, "src": "3183:7:49", "typeDescriptions": { "typeIdentifier": "t_modifier$_t_address_$", "typeString": "modifier (address)" } }, "nodeType": "ModifierInvocation", "src": "3183:12:49" } ], "name": "transfer", "nodeType": "FunctionDefinition", "overrides": { "id": 20788, "nodeType": "OverrideSpecifier", "overrides": [ { "contractScope": null, "id": 20786, "name": "IERC20Token", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 21462, "src": "3149:11:49", "typeDescriptions": { "typeIdentifier": "t_contract$_IERC20Token_$21462", "typeString": "contract IERC20Token" } }, { "contractScope": null, "id": 20787, "name": "ERC20Token", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 20617, "src": "3162:10:49", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$20617", "typeString": "contract ERC20Token" } } ], "src": "3140:33:49" }, "parameters": { "id": 20785, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20782, "mutability": "mutable", "name": "_to", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20802, "src": "3086:11:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 20781, "name": "address", "nodeType": "ElementaryTypeName", "src": "3086:7:49", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 20784, "mutability": "mutable", "name": "_value", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20802, "src": "3099:14:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 20783, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "3099:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "3085:29:49" }, "returnParameters": { "id": 20794, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20793, "mutability": "mutable", "name": "", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20802, "src": "3214:4:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 20792, "name": "bool", "nodeType": "ElementaryTypeName", "src": "3214:4:49", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "internal" } ], "src": "3213:6:49" }, "scope": 20837, "src": "3068:210:49", "stateMutability": "nonpayable", "virtual": false, "visibility": "public" }, { "baseFunctions": [ 20567, 21452 ], "body": { "id": 20827, "nodeType": "Block", "src": "3836:64:49", "statements": [ { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 20822, "name": "_from", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20805, "src": "3873:5:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 20823, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20807, "src": "3880:3:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 20824, "name": "_value", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20809, "src": "3885:6:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "id": 20820, "name": "super", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -25, "src": "3854:5:49", "typeDescriptions": { "typeIdentifier": "t_super$_EtherToken_$20837", "typeString": "contract super EtherToken" } }, "id": 20821, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "transferFrom", "nodeType": "MemberAccess", "referencedDeclaration": 20567, "src": "3854:18:49", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$_t_bool_$", "typeString": "function (address,address,uint256) returns (bool)" } }, "id": 20825, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "3854:38:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "functionReturnParameters": 20819, "id": 20826, "nodeType": "Return", "src": "3847:45:49" } ] }, "documentation": { "id": 20803, "nodeType": "StructuredDocumentation", "src": "3286:368:49", "text": " @dev an account/contract attempts to get the coins\n throws on any error rather then return a false flag to minimize user errors\n @param _from source address\n @param _to target address\n @param _value transfer amount\n @return true if the transfer was successful, false if it wasn't" }, "functionSelector": "23b872dd", "id": 20828, "implemented": true, "kind": "function", "modifiers": [ { "arguments": [ { "argumentTypes": null, "id": 20815, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20807, "src": "3802:3:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } } ], "id": 20816, "modifierName": { "argumentTypes": null, "id": 20814, "name": "notThis", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 22979, "src": "3794:7:49", "typeDescriptions": { "typeIdentifier": "t_modifier$_t_address_$", "typeString": "modifier (address)" } }, "nodeType": "ModifierInvocation", "src": "3794:12:49" } ], "name": "transferFrom", "nodeType": "FunctionDefinition", "overrides": { "id": 20813, "nodeType": "OverrideSpecifier", "overrides": [ { "contractScope": null, "id": 20811, "name": "IERC20Token", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 21462, "src": "3760:11:49", "typeDescriptions": { "typeIdentifier": "t_contract$_IERC20Token_$21462", "typeString": "contract IERC20Token" } }, { "contractScope": null, "id": 20812, "name": "ERC20Token", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 20617, "src": "3773:10:49", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$20617", "typeString": "contract ERC20Token" } } ], "src": "3751:33:49" }, "parameters": { "id": 20810, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20805, "mutability": "mutable", "name": "_from", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20828, "src": "3682:13:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 20804, "name": "address", "nodeType": "ElementaryTypeName", "src": "3682:7:49", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 20807, "mutability": "mutable", "name": "_to", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20828, "src": "3697:11:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 20806, "name": "address", "nodeType": "ElementaryTypeName", "src": "3697:7:49", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 20809, "mutability": "mutable", "name": "_value", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20828, "src": "3710:14:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 20808, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "3710:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "3681:44:49" }, "returnParameters": { "id": 20819, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20818, "mutability": "mutable", "name": "", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20828, "src": "3825:4:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 20817, "name": "bool", "nodeType": "ElementaryTypeName", "src": "3825:4:49", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "internal" } ], "src": "3824:6:49" }, "scope": 20837, "src": "3660:240:49", "stateMutability": "nonpayable", "virtual": false, "visibility": "public" }, { "body": { "id": 20835, "nodeType": "Block", "src": "3995:28:49", "statements": [ { "expression": { "argumentTypes": null, "arguments": [], "expression": { "argumentTypes": [], "id": 20832, "name": "deposit", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20666, "src": "4006:7:49", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$", "typeString": "function ()" } }, "id": 20833, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "4006:9:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 20834, "nodeType": "ExpressionStatement", "src": "4006:9:49" } ] }, "documentation": { "id": 20829, "nodeType": "StructuredDocumentation", "src": "3908:54:49", "text": " @dev deposit ether in the account" }, "id": 20836, "implemented": true, "kind": "receive", "modifiers": [], "name": "", "nodeType": "FunctionDefinition", "overrides": null, "parameters": { "id": 20830, "nodeType": "ParameterList", "parameters": [], "src": "3975:2:49" }, "returnParameters": { "id": 20831, "nodeType": "ParameterList", "parameters": [], "src": "3995:0:49" }, "scope": 20837, "src": "3968:55:49", "stateMutability": "payable", "virtual": false, "visibility": "external" } ], "scope": 20838, "src": "289:3737:49" } ], "src": "52:3976:49" }, "legacyAST": { "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/EtherToken.sol", "exportedSymbols": { "EtherToken": [ 20837 ] }, "id": 20838, "license": "SEE LICENSE IN LICENSE", "nodeType": "SourceUnit", "nodes": [ { "id": 20619, "literals": [ "solidity", "0.6", ".12" ], "nodeType": "PragmaDirective", "src": "52:23:49" }, { "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/ERC20Token.sol", "file": "./ERC20Token.sol", "id": 20620, "nodeType": "ImportDirective", "scope": 20838, "sourceUnit": 20618, "src": "77:26:49", "symbolAliases": [], "unitAlias": "" }, { "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/token/interfaces/IEtherToken.sol", "file": "./interfaces/IEtherToken.sol", "id": 20621, "nodeType": "ImportDirective", "scope": 20838, "sourceUnit": 21489, "src": "105:38:49", "symbolAliases": [], "unitAlias": "" }, { "absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/SafeMath.sol", "file": "../utility/SafeMath.sol", "id": 20622, "nodeType": "ImportDirective", "scope": 20838, "sourceUnit": 22690, "src": "145:33:49", "symbolAliases": [], "unitAlias": "" }, { "abstract": false, "baseContracts": [ { "arguments": null, "baseName": { "contractScope": null, "id": 20624, "name": "IEtherToken", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 21488, "src": "312:11:49", "typeDescriptions": { "typeIdentifier": "t_contract$_IEtherToken_$21488", "typeString": "contract IEtherToken" } }, "id": 20625, "nodeType": "InheritanceSpecifier", "src": "312:11:49" }, { "arguments": null, "baseName": { "contractScope": null, "id": 20626, "name": "ERC20Token", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 20617, "src": "325:10:49", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$20617", "typeString": "contract ERC20Token" } }, "id": 20627, "nodeType": "InheritanceSpecifier", "src": "325:10:49" } ], "contractDependencies": [ 20617, 21462, 21488, 22996 ], "contractKind": "contract", "documentation": { "id": 20623, "nodeType": "StructuredDocumentation", "src": "182:105:49", "text": " @dev Ether tokenization contract\n 'Owned' is specified here for readability reasons" }, "fullyImplemented": true, "id": 20837, "linearizedBaseContracts": [ 20837, 20617, 22996, 21488, 21462 ], "name": "EtherToken", "nodeType": "ContractDefinition", "nodes": [ { "id": 20630, "libraryName": { "contractScope": null, "id": 20628, "name": "SafeMath", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 22689, "src": "349:8:49", "typeDescriptions": { "typeIdentifier": "t_contract$_SafeMath_$22689", "typeString": "library SafeMath" } }, "nodeType": "UsingForDirective", "src": "343:27:49", "typeName": { "id": 20629, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "362:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } }, { "anonymous": false, "documentation": { "id": 20631, "nodeType": "StructuredDocumentation", "src": "378:141:49", "text": " @dev triggered when the total supply is increased\n @param _amount amount that gets added to the supply" }, "id": 20635, "name": "Issuance", "nodeType": "EventDefinition", "parameters": { "id": 20634, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20633, "indexed": false, "mutability": "mutable", "name": "_amount", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20635, "src": "540:15:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 20632, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "540:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "539:17:49" }, "src": "525:32:49" }, { "anonymous": false, "documentation": { "id": 20636, "nodeType": "StructuredDocumentation", "src": "565:145:49", "text": " @dev triggered when the total supply is decreased\n @param _amount amount that gets removed from the supply" }, "id": 20640, "name": "Destruction", "nodeType": "EventDefinition", "parameters": { "id": 20639, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20638, "indexed": false, "mutability": "mutable", "name": "_amount", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20640, "src": "734:15:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 20637, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "734:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "733:17:49" }, "src": "716:35:49" }, { "body": { "id": 20654, "nodeType": "Block", "src": "1034:8:49", "statements": [] }, "documentation": { "id": 20641, "nodeType": "StructuredDocumentation", "src": "759:154:49", "text": " @dev initializes a new EtherToken instance\n @param _name token name\n @param _symbol token symbol" }, "id": 20655, "implemented": true, "kind": "constructor", "modifiers": [ { "arguments": [ { "argumentTypes": null, "id": 20648, "name": "_name", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20643, "src": "1011:5:49", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string memory" } }, { "argumentTypes": null, "id": 20649, "name": "_symbol", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20645, "src": "1018:7:49", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string memory" } }, { "argumentTypes": null, "hexValue": "3138", "id": 20650, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", "src": "1027:2:49", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_18_by_1", "typeString": "int_const 18" }, "value": "18" }, { "argumentTypes": null, "hexValue": "30", "id": 20651, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", "src": "1031:1:49", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", "typeString": "int_const 0" }, "value": "0" } ], "id": 20652, "modifierName": { "argumentTypes": null, "id": 20647, "name": "ERC20Token", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20617, "src": "1000:10:49", "typeDescriptions": { "typeIdentifier": "t_type$_t_contract$_ERC20Token_$20617_$", "typeString": "type(contract ERC20Token)" } }, "nodeType": "ModifierInvocation", "src": "1000:33:49" } ], "name": "", "nodeType": "FunctionDefinition", "overrides": null, "parameters": { "id": 20646, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20643, "mutability": "mutable", "name": "_name", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20655, "src": "931:19:49", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string" }, "typeName": { "id": 20642, "name": "string", "nodeType": "ElementaryTypeName", "src": "931:6:49", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 20645, "mutability": "mutable", "name": "_symbol", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20655, "src": "952:21:49", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { "typeIdentifier": "t_string_memory_ptr", "typeString": "string" }, "typeName": { "id": 20644, "name": "string", "nodeType": "ElementaryTypeName", "src": "952:6:49", "typeDescriptions": { "typeIdentifier": "t_string_storage_ptr", "typeString": "string" } }, "value": null, "visibility": "internal" } ], "src": "930:44:49" }, "returnParameters": { "id": 20653, "nodeType": "ParameterList", "parameters": [], "src": "1034:0:49" }, "scope": 20837, "src": "919:123:49", "stateMutability": "nonpayable", "virtual": false, "visibility": "public" }, { "baseFunctions": [ 21470 ], "body": { "id": 20665, "nodeType": "Block", "src": "1162:40:49", "statements": [ { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20661, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "1183:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20662, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1183:10:49", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address_payable", "typeString": "address payable" } ], "id": 20660, "name": "depositTo", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20726, "src": "1173:9:49", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$", "typeString": "function (address)" } }, "id": 20663, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1173:21:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 20664, "nodeType": "ExpressionStatement", "src": "1173:21:49" } ] }, "documentation": { "id": 20656, "nodeType": "StructuredDocumentation", "src": "1050:63:49", "text": " @dev deposit ether on behalf of the sender" }, "functionSelector": "d0e30db0", "id": 20666, "implemented": true, "kind": "function", "modifiers": [], "name": "deposit", "nodeType": "FunctionDefinition", "overrides": { "id": 20658, "nodeType": "OverrideSpecifier", "overrides": [], "src": "1145:8:49" }, "parameters": { "id": 20657, "nodeType": "ParameterList", "parameters": [], "src": "1135:2:49" }, "returnParameters": { "id": 20659, "nodeType": "ParameterList", "parameters": [], "src": "1162:0:49" }, "scope": 20837, "src": "1119:83:49", "stateMutability": "payable", "virtual": false, "visibility": "public" }, { "baseFunctions": [ 21475 ], "body": { "id": 20679, "nodeType": "Block", "src": "1393:50:49", "statements": [ { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20674, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "1415:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20675, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1415:10:49", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, { "argumentTypes": null, "id": 20676, "name": "_amount", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20669, "src": "1427:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address_payable", "typeString": "address payable" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "id": 20673, "name": "withdrawTo", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20779, "src": "1404:10:49", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_payable_$_t_uint256_$returns$__$", "typeString": "function (address payable,uint256)" } }, "id": 20677, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1404:31:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 20678, "nodeType": "ExpressionStatement", "src": "1404:31:49" } ] }, "documentation": { "id": 20667, "nodeType": "StructuredDocumentation", "src": "1210:126:49", "text": " @dev withdraw ether to the sender's account\n @param _amount amount of ether to withdraw" }, "functionSelector": "2e1a7d4d", "id": 20680, "implemented": true, "kind": "function", "modifiers": [], "name": "withdraw", "nodeType": "FunctionDefinition", "overrides": { "id": 20671, "nodeType": "OverrideSpecifier", "overrides": [], "src": "1384:8:49" }, "parameters": { "id": 20670, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20669, "mutability": "mutable", "name": "_amount", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20680, "src": "1360:15:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 20668, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "1360:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "1359:17:49" }, "returnParameters": { "id": 20672, "nodeType": "ParameterList", "parameters": [], "src": "1393:0:49" }, "scope": 20837, "src": "1342:101:49", "stateMutability": "nonpayable", "virtual": false, "visibility": "public" }, { "baseFunctions": [ 21480 ], "body": { "id": 20725, "nodeType": "Block", "src": "1712:277:49", "statements": [ { "expression": { "argumentTypes": null, "id": 20700, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 20690, "name": "balanceOf", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20369, "src": "1723:9:49", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, "id": 20692, "indexExpression": { "argumentTypes": null, "id": 20691, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20683, "src": "1733:3:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "nodeType": "IndexAccess", "src": "1723:14:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20697, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "1759:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20698, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1759:9:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 20693, "name": "balanceOf", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20369, "src": "1740:9:49", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, "id": 20695, "indexExpression": { "argumentTypes": null, "id": 20694, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20683, "src": "1750:3:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "1740:14:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 20696, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "add", "nodeType": "MemberAccess", "referencedDeclaration": 22606, "src": "1740:18:49", "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": 20699, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1740:29:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "src": "1723:46:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 20701, "nodeType": "ExpressionStatement", "src": "1723:46:49" }, { "expression": { "argumentTypes": null, "id": 20708, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "id": 20702, "name": "totalSupply", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20364, "src": "1820:11:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20705, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "1850:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20706, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1850:9:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "id": 20703, "name": "totalSupply", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20364, "src": "1834:11:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 20704, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "add", "nodeType": "MemberAccess", "referencedDeclaration": 22606, "src": "1834:15:49", "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": 20707, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1834:26:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "src": "1820:40:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 20709, "nodeType": "ExpressionStatement", "src": "1820:40:49" }, { "eventCall": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20711, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "1916:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20712, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1916:9:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "id": 20710, "name": "Issuance", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20635, "src": "1907:8:49", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_uint256_$returns$__$", "typeString": "function (uint256)" } }, "id": 20713, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1907:19:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 20714, "nodeType": "EmitStatement", "src": "1902:24:49" }, { "eventCall": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 20718, "name": "this", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -28, "src": "1959:4:49", "typeDescriptions": { "typeIdentifier": "t_contract$_EtherToken_$20837", "typeString": "contract EtherToken" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_contract$_EtherToken_$20837", "typeString": "contract EtherToken" } ], "id": 20717, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", "src": "1951:7:49", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": { "id": 20716, "name": "address", "nodeType": "ElementaryTypeName", "src": "1951:7:49", "typeDescriptions": { "typeIdentifier": null, "typeString": null } } }, "id": 20719, "isConstant": false, "isLValue": false, "isPure": false, "kind": "typeConversion", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1951:13:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, { "argumentTypes": null, "id": 20720, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20683, "src": "1966:3:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20721, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "1971:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20722, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "1971:9:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address_payable", "typeString": "address payable" }, { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "id": 20715, "name": "Transfer", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20385, "src": "1942:8:49", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, "id": 20723, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "1942:39:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 20724, "nodeType": "EmitStatement", "src": "1937:44:49" } ] }, "documentation": { "id": 20681, "nodeType": "StructuredDocumentation", "src": "1451:145:49", "text": " @dev deposit ether to be entitled for a given account\n @param _to account to be entitled for the ether" }, "functionSelector": "b760faf9", "id": 20726, "implemented": true, "kind": "function", "modifiers": [ { "arguments": [ { "argumentTypes": null, "id": 20687, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20683, "src": "1702:3:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } } ], "id": 20688, "modifierName": { "argumentTypes": null, "id": 20686, "name": "notThis", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 22979, "src": "1694:7:49", "typeDescriptions": { "typeIdentifier": "t_modifier$_t_address_$", "typeString": "modifier (address)" } }, "nodeType": "ModifierInvocation", "src": "1694:12:49" } ], "name": "depositTo", "nodeType": "FunctionDefinition", "overrides": { "id": 20685, "nodeType": "OverrideSpecifier", "overrides": [], "src": "1659:8:49" }, "parameters": { "id": 20684, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20683, "mutability": "mutable", "name": "_to", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20726, "src": "1621:11:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 20682, "name": "address", "nodeType": "ElementaryTypeName", "src": "1621:7:49", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" } ], "src": "1620:13:49" }, "returnParameters": { "id": 20689, "nodeType": "ParameterList", "parameters": [], "src": "1712:0:49" }, "scope": 20837, "src": "1602:387:49", "stateMutability": "payable", "virtual": false, "visibility": "public" }, { "baseFunctions": [ 21487 ], "body": { "id": 20778, "nodeType": "Block", "src": "2320:372:49", "statements": [ { "expression": { "argumentTypes": null, "id": 20749, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 20738, "name": "balanceOf", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20369, "src": "2331:9:49", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, "id": 20741, "indexExpression": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20739, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "2341:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20740, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "2341:10:49", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": true, "nodeType": "IndexAccess", "src": "2331:21:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 20747, "name": "_amount", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20731, "src": "2381:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, "id": 20742, "name": "balanceOf", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20369, "src": "2355:9:49", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, "id": 20745, "indexExpression": { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20743, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "2365:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20744, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "2365:10:49", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", "src": "2355:21:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 20746, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sub", "nodeType": "MemberAccess", "referencedDeclaration": 22628, "src": "2355:25:49", "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": 20748, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "2355:34:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "src": "2331:58:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 20750, "nodeType": "ExpressionStatement", "src": "2331:58:49" }, { "expression": { "argumentTypes": null, "id": 20756, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, "id": 20751, "name": "totalSupply", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20364, "src": "2446:11:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "Assignment", "operator": "=", "rightHandSide": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 20754, "name": "_amount", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20731, "src": "2476:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "id": 20752, "name": "totalSupply", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20364, "src": "2460:11:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 20753, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sub", "nodeType": "MemberAccess", "referencedDeclaration": 22628, "src": "2460:15:49", "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": 20755, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "2460:24:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "src": "2446:38:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "id": 20757, "nodeType": "ExpressionStatement", "src": "2446:38:49" }, { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 20761, "name": "_amount", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20731, "src": "2537:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "id": 20758, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20729, "src": "2524:3:49", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, "id": 20760, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "transfer", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "2524:12:49", "typeDescriptions": { "typeIdentifier": "t_function_transfer_nonpayable$_t_uint256_$returns$__$", "typeString": "function (uint256)" } }, "id": 20762, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "2524:21:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 20763, "nodeType": "ExpressionStatement", "src": "2524:21:49" }, { "eventCall": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "expression": { "argumentTypes": null, "id": 20765, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -15, "src": "2613:3:49", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, "id": 20766, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, "src": "2613:10:49", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 20769, "name": "this", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -28, "src": "2633:4:49", "typeDescriptions": { "typeIdentifier": "t_contract$_EtherToken_$20837", "typeString": "contract EtherToken" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_contract$_EtherToken_$20837", "typeString": "contract EtherToken" } ], "id": 20768, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", "src": "2625:7:49", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": { "id": 20767, "name": "address", "nodeType": "ElementaryTypeName", "src": "2625:7:49", "typeDescriptions": { "typeIdentifier": null, "typeString": null } } }, "id": 20770, "isConstant": false, "isLValue": false, "isPure": false, "kind": "typeConversion", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "2625:13:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, { "argumentTypes": null, "id": 20771, "name": "_amount", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20731, "src": "2640:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address_payable", "typeString": "address payable" }, { "typeIdentifier": "t_address_payable", "typeString": "address payable" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "id": 20764, "name": "Transfer", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20385, "src": "2604:8:49", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, "id": 20772, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "2604:44:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 20773, "nodeType": "EmitStatement", "src": "2599:49:49" }, { "eventCall": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 20775, "name": "_amount", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20731, "src": "2676:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "id": 20774, "name": "Destruction", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20640, "src": "2664:11:49", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_uint256_$returns$__$", "typeString": "function (uint256)" } }, "id": 20776, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "2664:20:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 20777, "nodeType": "EmitStatement", "src": "2659:25:49" } ] }, "documentation": { "id": 20727, "nodeType": "StructuredDocumentation", "src": "1997:198:49", "text": " @dev withdraw ether entitled by the sender to a given account\n @param _to account to receive the ether\n @param _amount amount of ether to withdraw" }, "functionSelector": "205c2878", "id": 20779, "implemented": true, "kind": "function", "modifiers": [ { "arguments": [ { "argumentTypes": null, "id": 20735, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20729, "src": "2310:3:49", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } } ], "id": 20736, "modifierName": { "argumentTypes": null, "id": 20734, "name": "notThis", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 22979, "src": "2302:7:49", "typeDescriptions": { "typeIdentifier": "t_modifier$_t_address_$", "typeString": "modifier (address)" } }, "nodeType": "ModifierInvocation", "src": "2302:12:49" } ], "name": "withdrawTo", "nodeType": "FunctionDefinition", "overrides": { "id": 20733, "nodeType": "OverrideSpecifier", "overrides": [], "src": "2284:8:49" }, "parameters": { "id": 20732, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20729, "mutability": "mutable", "name": "_to", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20779, "src": "2221:19:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" }, "typeName": { "id": 20728, "name": "address", "nodeType": "ElementaryTypeName", "src": "2221:15:49", "stateMutability": "payable", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 20731, "mutability": "mutable", "name": "_amount", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20779, "src": "2242:15:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 20730, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "2242:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "2220:38:49" }, "returnParameters": { "id": 20737, "nodeType": "ParameterList", "parameters": [], "src": "2320:0:49" }, "scope": 20837, "src": "2201:491:49", "stateMutability": "nonpayable", "virtual": false, "visibility": "public" }, { "baseFunctions": [ 20500, 21441 ], "body": { "id": 20801, "nodeType": "Block", "src": "3225:53:49", "statements": [ { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 20797, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20782, "src": "3258:3:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 20798, "name": "_value", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20784, "src": "3263:6:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "id": 20795, "name": "super", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -25, "src": "3243:5:49", "typeDescriptions": { "typeIdentifier": "t_super$_EtherToken_$20837", "typeString": "contract super EtherToken" } }, "id": 20796, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "transfer", "nodeType": "MemberAccess", "referencedDeclaration": 20500, "src": "3243:14:49", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$", "typeString": "function (address,uint256) returns (bool)" } }, "id": 20799, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "3243:27:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "functionReturnParameters": 20794, "id": 20800, "nodeType": "Return", "src": "3236:34:49" } ] }, "documentation": { "id": 20780, "nodeType": "StructuredDocumentation", "src": "2769:293:49", "text": " @dev send coins\n throws on any error rather then return a false flag to minimize user errors\n @param _to target address\n @param _value transfer amount\n @return true if the transfer was successful, false if it wasn't" }, "functionSelector": "a9059cbb", "id": 20802, "implemented": true, "kind": "function", "modifiers": [ { "arguments": [ { "argumentTypes": null, "id": 20790, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20782, "src": "3191:3:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } } ], "id": 20791, "modifierName": { "argumentTypes": null, "id": 20789, "name": "notThis", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 22979, "src": "3183:7:49", "typeDescriptions": { "typeIdentifier": "t_modifier$_t_address_$", "typeString": "modifier (address)" } }, "nodeType": "ModifierInvocation", "src": "3183:12:49" } ], "name": "transfer", "nodeType": "FunctionDefinition", "overrides": { "id": 20788, "nodeType": "OverrideSpecifier", "overrides": [ { "contractScope": null, "id": 20786, "name": "IERC20Token", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 21462, "src": "3149:11:49", "typeDescriptions": { "typeIdentifier": "t_contract$_IERC20Token_$21462", "typeString": "contract IERC20Token" } }, { "contractScope": null, "id": 20787, "name": "ERC20Token", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 20617, "src": "3162:10:49", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$20617", "typeString": "contract ERC20Token" } } ], "src": "3140:33:49" }, "parameters": { "id": 20785, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20782, "mutability": "mutable", "name": "_to", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20802, "src": "3086:11:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 20781, "name": "address", "nodeType": "ElementaryTypeName", "src": "3086:7:49", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 20784, "mutability": "mutable", "name": "_value", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20802, "src": "3099:14:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 20783, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "3099:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "3085:29:49" }, "returnParameters": { "id": 20794, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20793, "mutability": "mutable", "name": "", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20802, "src": "3214:4:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 20792, "name": "bool", "nodeType": "ElementaryTypeName", "src": "3214:4:49", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "internal" } ], "src": "3213:6:49" }, "scope": 20837, "src": "3068:210:49", "stateMutability": "nonpayable", "virtual": false, "visibility": "public" }, { "baseFunctions": [ 20567, 21452 ], "body": { "id": 20827, "nodeType": "Block", "src": "3836:64:49", "statements": [ { "expression": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, "id": 20822, "name": "_from", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20805, "src": "3873:5:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 20823, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20807, "src": "3880:3:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, { "argumentTypes": null, "id": 20824, "name": "_value", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20809, "src": "3885:6:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } } ], "expression": { "argumentTypes": [ { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_address", "typeString": "address" }, { "typeIdentifier": "t_uint256", "typeString": "uint256" } ], "expression": { "argumentTypes": null, "id": 20820, "name": "super", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": -25, "src": "3854:5:49", "typeDescriptions": { "typeIdentifier": "t_super$_EtherToken_$20837", "typeString": "contract super EtherToken" } }, "id": 20821, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "transferFrom", "nodeType": "MemberAccess", "referencedDeclaration": 20567, "src": "3854:18:49", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$_t_bool_$", "typeString": "function (address,address,uint256) returns (bool)" } }, "id": 20825, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "3854:38:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "functionReturnParameters": 20819, "id": 20826, "nodeType": "Return", "src": "3847:45:49" } ] }, "documentation": { "id": 20803, "nodeType": "StructuredDocumentation", "src": "3286:368:49", "text": " @dev an account/contract attempts to get the coins\n throws on any error rather then return a false flag to minimize user errors\n @param _from source address\n @param _to target address\n @param _value transfer amount\n @return true if the transfer was successful, false if it wasn't" }, "functionSelector": "23b872dd", "id": 20828, "implemented": true, "kind": "function", "modifiers": [ { "arguments": [ { "argumentTypes": null, "id": 20815, "name": "_to", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20807, "src": "3802:3:49", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } } ], "id": 20816, "modifierName": { "argumentTypes": null, "id": 20814, "name": "notThis", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 22979, "src": "3794:7:49", "typeDescriptions": { "typeIdentifier": "t_modifier$_t_address_$", "typeString": "modifier (address)" } }, "nodeType": "ModifierInvocation", "src": "3794:12:49" } ], "name": "transferFrom", "nodeType": "FunctionDefinition", "overrides": { "id": 20813, "nodeType": "OverrideSpecifier", "overrides": [ { "contractScope": null, "id": 20811, "name": "IERC20Token", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 21462, "src": "3760:11:49", "typeDescriptions": { "typeIdentifier": "t_contract$_IERC20Token_$21462", "typeString": "contract IERC20Token" } }, { "contractScope": null, "id": 20812, "name": "ERC20Token", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 20617, "src": "3773:10:49", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$20617", "typeString": "contract ERC20Token" } } ], "src": "3751:33:49" }, "parameters": { "id": 20810, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20805, "mutability": "mutable", "name": "_from", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20828, "src": "3682:13:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 20804, "name": "address", "nodeType": "ElementaryTypeName", "src": "3682:7:49", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 20807, "mutability": "mutable", "name": "_to", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20828, "src": "3697:11:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" }, "typeName": { "id": 20806, "name": "address", "nodeType": "ElementaryTypeName", "src": "3697:7:49", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "value": null, "visibility": "internal" }, { "constant": false, "id": 20809, "mutability": "mutable", "name": "_value", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20828, "src": "3710:14:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, "typeName": { "id": 20808, "name": "uint256", "nodeType": "ElementaryTypeName", "src": "3710:7:49", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "value": null, "visibility": "internal" } ], "src": "3681:44:49" }, "returnParameters": { "id": 20819, "nodeType": "ParameterList", "parameters": [ { "constant": false, "id": 20818, "mutability": "mutable", "name": "", "nodeType": "VariableDeclaration", "overrides": null, "scope": 20828, "src": "3825:4:49", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" }, "typeName": { "id": 20817, "name": "bool", "nodeType": "ElementaryTypeName", "src": "3825:4:49", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "value": null, "visibility": "internal" } ], "src": "3824:6:49" }, "scope": 20837, "src": "3660:240:49", "stateMutability": "nonpayable", "virtual": false, "visibility": "public" }, { "body": { "id": 20835, "nodeType": "Block", "src": "3995:28:49", "statements": [ { "expression": { "argumentTypes": null, "arguments": [], "expression": { "argumentTypes": [], "id": 20832, "name": "deposit", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 20666, "src": "4006:7:49", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$", "typeString": "function ()" } }, "id": 20833, "isConstant": false, "isLValue": false, "isPure": false, "kind": "functionCall", "lValueRequested": false, "names": [], "nodeType": "FunctionCall", "src": "4006:9:49", "tryCall": false, "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, "id": 20834, "nodeType": "ExpressionStatement", "src": "4006:9:49" } ] }, "documentation": { "id": 20829, "nodeType": "StructuredDocumentation", "src": "3908:54:49", "text": " @dev deposit ether in the account" }, "id": 20836, "implemented": true, "kind": "receive", "modifiers": [], "name": "", "nodeType": "FunctionDefinition", "overrides": null, "parameters": { "id": 20830, "nodeType": "ParameterList", "parameters": [], "src": "3975:2:49" }, "returnParameters": { "id": 20831, "nodeType": "ParameterList", "parameters": [], "src": "3995:0:49" }, "scope": 20837, "src": "3968:55:49", "stateMutability": "payable", "virtual": false, "visibility": "external" } ], "scope": 20838, "src": "289:3737:49" } ], "src": "52:3976:49" }, "compiler": { "name": "solc", "version": "0.6.12+commit.27d51765.Emscripten.clang" }, "networks": { "1604964387852": { "events": { "0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925": { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "address", "name": "_owner", "type": "address" }, { "indexed": true, "internalType": "address", "name": "_spender", "type": "address" }, { "indexed": false, "internalType": "uint256", "name": "_value", "type": "uint256" } ], "name": "Approval", "type": "event" }, "0x9a1b418bc061a5d80270261562e6986a35d995f8051145f277be16103abd3453": { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "_amount", "type": "uint256" } ], "name": "Destruction", "type": "event" }, "0x9386c90217c323f58030f9dadcbc938f807a940f4ff41cd4cead9562f5da7dc3": { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "_amount", "type": "uint256" } ], "name": "Issuance", "type": "event" }, "0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef": { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "address", "name": "_from", "type": "address" }, { "indexed": true, "internalType": "address", "name": "_to", "type": "address" }, { "indexed": false, "internalType": "uint256", "name": "_value", "type": "uint256" } ], "name": "Transfer", "type": "event" } }, "links": {}, "address": "0x3ca82B266Eb2A5E7D3ff0443A3E77dcFd3FCd951", "transactionHash": "0x5e1c72f8309ca075596126269006d74a8ec61048c8734c393b5e3dadf17c0c50" }, "1604964469407": { "events": { "0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925": { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "address", "name": "_owner", "type": "address" }, { "indexed": true, "internalType": "address", "name": "_spender", "type": "address" }, { "indexed": false, "internalType": "uint256", "name": "_value", "type": "uint256" } ], "name": "Approval", "type": "event" }, "0x9a1b418bc061a5d80270261562e6986a35d995f8051145f277be16103abd3453": { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "_amount", "type": "uint256" } ], "name": "Destruction", "type": "event" }, "0x9386c90217c323f58030f9dadcbc938f807a940f4ff41cd4cead9562f5da7dc3": { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint256", "name": "_amount", "type": "uint256" } ], "name": "Issuance", "type": "event" }, "0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef": { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "address", "name": "_from", "type": "address" }, { "indexed": true, "internalType": "address", "name": "_to", "type": "address" }, { "indexed": false, "internalType": "uint256", "name": "_value", "type": "uint256" } ], "name": "Transfer", "type": "event" } }, "links": {}, "address": "0x86839ff49c3eAb7aB85A136883C378E97990C787", "transactionHash": "0xd86501bcab8952303093ff4814e23edd93484236a1a59c1821cdbe16c425a12c" } }, "schemaVersion": "3.2.3", "updatedAt": "2020-11-10T14:20:45.584Z", "networkType": "ethereum", "devdoc": { "details": "Ether tokenization contract 'Owned' is specified here for readability reasons", "events": { "Destruction(uint256)": { "details": "triggered when the total supply is decreased", "params": { "_amount": "amount that gets removed from the supply" } }, "Issuance(uint256)": { "details": "triggered when the total supply is increased", "params": { "_amount": "amount that gets added to the supply" } } }, "kind": "dev", "methods": { "approve(address,uint256)": { "details": "allows another account/contract to transfers tokens on behalf of the caller throws on any error rather then return a false flag to minimize user errors also, to minimize the risk of the approve/transferFrom attack vector (see https://docs.google.com/document/d/1YLPtQxZu1UAvO9cZ1O2RPXBbT0mooh4DYKjA_jp-RLM/), approve has to be called twice in 2 separate transactions - once to change the allowance to 0 and secondly to change it to the new allowance value", "params": { "_spender": "approved address", "_value": "allowance amount" }, "returns": { "_0": "true if the approval was successful, false if it wasn't" } }, "constructor": { "details": "initializes a new EtherToken instance", "params": { "_name": "token name", "_symbol": "token symbol" } }, "deposit()": { "details": "deposit ether on behalf of the sender" }, "depositTo(address)": { "details": "deposit ether to be entitled for a given account", "params": { "_to": "account to be entitled for the ether" } }, "transfer(address,uint256)": { "details": "send coins throws on any error rather then return a false flag to minimize user errors", "params": { "_to": "target address", "_value": "transfer amount" }, "returns": { "_0": "true if the transfer was successful, false if it wasn't" } }, "transferFrom(address,address,uint256)": { "details": "an account/contract attempts to get the coins throws on any error rather then return a false flag to minimize user errors", "params": { "_from": "source address", "_to": "target address", "_value": "transfer amount" }, "returns": { "_0": "true if the transfer was successful, false if it wasn't" } }, "withdraw(uint256)": { "details": "withdraw ether to the sender's account", "params": { "_amount": "amount of ether to withdraw" } }, "withdrawTo(address,uint256)": { "details": "withdraw ether entitled by the sender to a given account", "params": { "_amount": "amount of ether to withdraw", "_to": "account to receive the ether" } } }, "version": 1 }, "userdoc": { "kind": "user", "methods": {}, "version": 1 } }