14790 lines
694 KiB
JSON
14790 lines
694 KiB
JSON
{
|
|
"contractName": "ConversionPathFinder",
|
|
"abi": [
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "contract IContractRegistry",
|
|
"name": "_registry",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"stateMutability": "nonpayable",
|
|
"type": "constructor"
|
|
},
|
|
{
|
|
"anonymous": false,
|
|
"inputs": [
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_prevOwner",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_newOwner",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "OwnerUpdate",
|
|
"type": "event"
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "acceptOwnership",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "anchorToken",
|
|
"outputs": [
|
|
{
|
|
"internalType": "contract IERC20Token",
|
|
"name": "",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function",
|
|
"constant": true
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "newOwner",
|
|
"outputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function",
|
|
"constant": true
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "onlyOwnerCanUpdateRegistry",
|
|
"outputs": [
|
|
{
|
|
"internalType": "bool",
|
|
"name": "",
|
|
"type": "bool"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function",
|
|
"constant": true
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "owner",
|
|
"outputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function",
|
|
"constant": true
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "prevRegistry",
|
|
"outputs": [
|
|
{
|
|
"internalType": "contract IContractRegistry",
|
|
"name": "",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function",
|
|
"constant": true
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "registry",
|
|
"outputs": [
|
|
{
|
|
"internalType": "contract IContractRegistry",
|
|
"name": "",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function",
|
|
"constant": true
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "restoreRegistry",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "bool",
|
|
"name": "_onlyOwnerCanUpdateRegistry",
|
|
"type": "bool"
|
|
}
|
|
],
|
|
"name": "restrictRegistryUpdate",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "_newOwner",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "transferOwnership",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "updateRegistry",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "contract IERC20Token",
|
|
"name": "_anchorToken",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "setAnchorToken",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "contract IERC20Token",
|
|
"name": "_sourceToken",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"internalType": "contract IERC20Token",
|
|
"name": "_targetToken",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "findPath",
|
|
"outputs": [
|
|
{
|
|
"internalType": "address[]",
|
|
"name": "",
|
|
"type": "address[]"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function",
|
|
"constant": true
|
|
}
|
|
],
|
|
"metadata": "{\"compiler\":{\"version\":\"0.6.12+commit.27d51765\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"contract IContractRegistry\",\"name\":\"_registry\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"_prevOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"_newOwner\",\"type\":\"address\"}],\"name\":\"OwnerUpdate\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"anchorToken\",\"outputs\":[{\"internalType\":\"contract IERC20Token\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contract IERC20Token\",\"name\":\"_sourceToken\",\"type\":\"address\"},{\"internalType\":\"contract IERC20Token\",\"name\":\"_targetToken\",\"type\":\"address\"}],\"name\":\"findPath\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"newOwner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"onlyOwnerCanUpdateRegistry\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"prevRegistry\",\"outputs\":[{\"internalType\":\"contract IContractRegistry\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contract IContractRegistry\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"restoreRegistry\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"_onlyOwnerCanUpdateRegistry\",\"type\":\"bool\"}],\"name\":\"restrictRegistryUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contract IERC20Token\",\"name\":\"_anchorToken\",\"type\":\"address\"}],\"name\":\"setAnchorToken\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateRegistry\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"details\":\"The ConversionPathFinder contract allows generating a conversion path between any token pair in the Bancor Network. The path can then be used in various functions in the BancorNetwork contract. See the BancorNetwork contract for conversion path format.\",\"kind\":\"dev\",\"methods\":{\"acceptOwnership()\":{\"details\":\"used by a new owner to accept an ownership transfer\"},\"constructor\":{\"details\":\"initializes a new ConversionPathFinder instance\",\"params\":{\"_registry\":\"address of a contract registry contract\"}},\"findPath(address,address)\":{\"details\":\"generates a conversion path between a given pair of tokens in the Bancor Network\",\"params\":{\"_sourceToken\":\"address of the source token\",\"_targetToken\":\"address of the target token\"},\"returns\":{\"_0\":\"a path from the source token to the target token\"}},\"restoreRegistry()\":{\"details\":\"restores the previous contract-registry\"},\"restrictRegistryUpdate(bool)\":{\"details\":\"restricts the permission to update the contract-registry\",\"params\":{\"_onlyOwnerCanUpdateRegistry\":\"indicates whether or not permission is restricted to owner only\"}},\"setAnchorToken(address)\":{\"details\":\"updates the anchor token\",\"params\":{\"_anchorToken\":\"address of the anchor token\"}},\"transferOwnership(address)\":{\"details\":\"allows transferring the contract ownership the new owner still needs to accept the transfer can only be called by the contract owner\",\"params\":{\"_newOwner\":\"new contract owner\"}},\"updateRegistry()\":{\"details\":\"updates to the new contract-registry\"}},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/ConversionPathFinder.sol\":\"ConversionPathFinder\"},\"evmVersion\":\"istanbul\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":200},\"remappings\":[]},\"sources\":{\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/ConversionPathFinder.sol\":{\"keccak256\":\"0x871b9cdd5219e84cdbb34d3c6ce58f7debed7d352bf1d10c34491512a4823817\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://9b041bd28c964c898204a6a59423335db04d13428edff9eed584d180e43f54e9\",\"dweb:/ipfs/QmetR7aSeGYHsUUhrHB6yZV5aRcuwUvN4EmcZzDoAPSLtQ\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/IConversionPathFinder.sol\":{\"keccak256\":\"0x2d0f5b57bc448581a6e2296486ca618851138f40928049d75220623605915d7b\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://2182eb05da8442792a5f3f4d8cdb2cf0bf9e952ca02638f3880cc59d5fd6dcb6\",\"dweb:/ipfs/QmSH9uWh6zTQkcBgD7VGGSzYW9DjdBDkUZUZ6zhzPWPPDz\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IConverter.sol\":{\"keccak256\":\"0x18b0d73a3d5ee951ede1b3f840ed35b40570e34975703079a4451555f4dd089b\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://1cd7263f1ef60793e3929509150420037df9a1194c3d0f40bb2ff5516d6a373f\",\"dweb:/ipfs/QmNUbsZt2rzWPjStYycgz3vMbNP4VrAqZPRAK39QNqUoos\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IConverterAnchor.sol\":{\"keccak256\":\"0x9448cdbe90293fb5c1a0808b77af8754a1025b59c45f432eee01f659361a6115\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://1ef2bb2e1543c9324daf7f3fd086a57efb45b89f3d62b9d7a9fc78c138d24dbc\",\"dweb:/ipfs/QmVcXDib3K6xYJMBNxawmo4krJGiDfxb5oL64Lc3pi14XK\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IConverterRegistry.sol\":{\"keccak256\":\"0x827d22d6c52b3e5128595090a3694847e9c54a760abf0e47a8870a7235537723\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://edae6c2f9f6fde390032189dda1b7f720521a31df5eb98e001d04bbf44dcfa02\",\"dweb:/ipfs/QmRz2EG3tcKeKXwHizciEr19ZEH2SidtQ9rkprKc6iR5Tz\"]},\"/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/utility/ContractRegistryClient.sol\":{\"keccak256\":\"0x74caf88eff1cb113ad8277df9ba7933a6f1e0deea8fd1855157def3be833b859\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://c7793c9f245736cd8413bc8c4b5c40b67949cbee32289a16d29c83cf59396ad6\",\"dweb:/ipfs/QmWony7b1buUrGnE32gjLAnSwkBYMrJ68vUcCwDMmp3MbJ\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/Owned.sol\":{\"keccak256\":\"0x6ef69d9dcc80a8a36d5eb37783375cd5e4831c6d20c723fa6f6b6a06c0aeb53d\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://5a5d087e2c5b47739615ef22e1f29749de44b43c9a37cfae32b3dfc498a258c4\",\"dweb:/ipfs/Qmd1mXKEQbmBxqHk326LGVzNoayXsam8gZNecknnYpBnyh\"]},\"/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\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/interfaces/IContractRegistry.sol\":{\"keccak256\":\"0x3551889a83738b621c29ed66f1ecb6a843cca4217e54c9357198559b9cc92259\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://231a59c8f2665adeda8c7e6930832409c9b991fd27ad84b3a24335e7bf269bbe\",\"dweb:/ipfs/QmeJJbn1EAUbZenruTEdJAnwUn3dxsVNeJvxPe81qKEGqL\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/interfaces/IOwned.sol\":{\"keccak256\":\"0xc60a9d197abc28c1906ed4d18b59caa0242db754a0e1f67af6e6277593530dae\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://a8c6f3e6525a81a5165ccbf04f73f6c389c14b74135d11a7b5f70b1c9bdac75c\",\"dweb:/ipfs/QmaPu4Z7yUPc9sMADmoTZVY6AnyDSYHtNNCx3mm4VkJwhP\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/interfaces/ITokenHolder.sol\":{\"keccak256\":\"0x9ccb8ab04d0bd874ba7aae5277e60f35c36918922649a0596bf3664ed257bfe2\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://b65e6db19cd244c9f3545695de5fd7573711c49fb306631ddbf0e1d2fa9fb589\",\"dweb:/ipfs/QmZeu5KYVMTbTx7h2BVUq52fpwL9Q44AUfzeVksucDohgf\"]},\"/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/interfaces/IWhitelist.sol\":{\"keccak256\":\"0x356ad553ceeaea04d7cb8f0d6a5663c47dfccb2bd82517348128f032416ee34a\",\"license\":\"SEE LICENSE IN LICENSE\",\"urls\":[\"bzz-raw://9ea3bbb9945144ead2c1392351f2f9f7444af78569f2b95da2e68bb6b919db52\",\"dweb:/ipfs/QmPyUAk44Kj7nJB4tzYqeSXWHyYP51mRNynEmWra9m4eKS\"]}},\"version\":1}",
|
|
"bytecode": "0x608060405234801561001057600080fd5b506040516110a73803806110a78339818101604052602081101561003357600080fd5b5051600080546001600160a01b03191633179055808061005281610083565b50600280546001600160a01b039092166001600160a01b0319928316811790915560038054909216179055506100e1565b6001600160a01b0381166100de576040805162461bcd60e51b815260206004820152601360248201527f4552525f494e56414c49445f4144445245535300000000000000000000000000604482015290519081900360640190fd5b50565b610fb7806100f06000396000f3fe608060405234801561001057600080fd5b50600436106100cf5760003560e01c80637b1039991161008c578063b4a176d311610066578063b4a176d3146101f9578063d4ee1d9014610201578063e1c4c96614610209578063f2fde38b14610211576100cf565b80637b1039991461016b5780638da5cb5b14610173578063a1c421cd1461017b576100cf565b8063024c7ec7146100d45780632f167f05146100f55780632fe8a6ad1461011b57806349d10b641461013757806361cd756e1461013f57806379ba509714610163575b600080fd5b6100f3600480360360208110156100ea57600080fd5b50351515610237565b005b6100f36004803603602081101561010b57600080fd5b50356001600160a01b031661025d565b610123610287565b604080519115158252519081900360200190f35b6100f3610297565b61014761049f565b604080516001600160a01b039092168252519081900360200190f35b6100f36104ae565b610147610565565b610147610574565b6101a96004803603604081101561019157600080fd5b506001600160a01b0381358116916020013516610583565b60408051602080825283518183015283519192839290830191858101910280838360005b838110156101e55781810151838201526020016101cd565b505050509050019250505060405180910390f35b6100f36105e4565b610147610610565b61014761061f565b6100f36004803603602081101561022757600080fd5b50356001600160a01b031661062e565b61023f6106ac565b60038054911515600160a01b0260ff60a01b19909216919091179055565b6102656106ac565b600480546001600160a01b0319166001600160a01b0392909216919091179055565b600354600160a01b900460ff1681565b6000546001600160a01b03163314806102ba5750600354600160a01b900460ff16155b6102ff576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b600061031d6f436f6e7472616374526567697374727960801b610701565b6002549091506001600160a01b0380831691161480159061034657506001600160a01b03811615155b61038e576040805162461bcd60e51b81526020600482015260146024820152734552525f494e56414c49445f524547495354525960601b604482015290519081900360640190fd5b60006001600160a01b0316816001600160a01b031663bb34534c6f436f6e7472616374526567697374727960801b6040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b1580156103f057600080fd5b505afa158015610404573d6000803e3d6000fd5b505050506040513d602081101561041a57600080fd5b50516001600160a01b0316141561046f576040805162461bcd60e51b81526020600482015260146024820152734552525f494e56414c49445f524547495354525960601b604482015290519081900360640190fd5b60028054600380546001600160a01b038084166001600160a01b0319928316179092559091169216919091179055565b6003546001600160a01b031681565b6001546001600160a01b03163314610501576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b600154600080546040516001600160a01b0393841693909116917f343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a91a360018054600080546001600160a01b03199081166001600160a01b03841617909155169055565b6002546001600160a01b031681565b6000546001600160a01b031681565b606060006105b07f42616e636f72436f6e7665727465725265676973747279000000000000000000610701565b905060606105be858361077f565b905060606105cc858461077f565b90506105d88282610b55565b93505050505b92915050565b6105ec6106ac565b600354600280546001600160a01b0319166001600160a01b03909216919091179055565b6001546001600160a01b031681565b6004546001600160a01b031681565b6106366106ac565b6000546001600160a01b038281169116141561068a576040805162461bcd60e51b815260206004820152600e60248201526d22a9292fa9a0a6a2afa7aba722a960911b604482015290519081900360640190fd5b600180546001600160a01b0319166001600160a01b0392909216919091179055565b6000546001600160a01b031633146106ff576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b565b60025460408051632ecd14d360e21b81526004810184905290516000926001600160a01b03169163bb34534c916024808301926020929190829003018186803b15801561074d57600080fd5b505afa158015610761573d6000803e3d6000fd5b505050506040513d602081101561077757600080fd5b505192915050565b6004546060906001600160a01b03848116911614156107a8576107a183610da7565b90506105de565b6060826001600160a01b031663d8cced2a856040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b1580156107f757600080fd5b505afa15801561080b573d6000803e3d6000fd5b505050506040513d602081101561082157600080fd5b5051156108385761083184610da7565b9050610951565b826001600160a01b03166311839064856040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060006040518083038186803b15801561088557600080fd5b505afa158015610899573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405260208110156108c257600080fd5b81019080805160405193929190846401000000008211156108e257600080fd5b9083019060208201858111156108f757600080fd5b825186602082028301116401000000008211171561091457600080fd5b82525081516020918201928201910280838360005b83811015610941578181015183820152602001610929565b5050505090500160405250505090505b60005b8151811015610b3957600082828151811061096b57fe5b60200260200101516001600160a01b0316638da5cb5b6040518163ffffffff1660e01b815260040160206040518083038186803b1580156109ab57600080fd5b505afa1580156109bf573d6000803e3d6000fd5b505050506040513d60208110156109d557600080fd5b5051604080516371f52bf360e01b815290519192506000916001600160a01b038416916371f52bf3916004808301926020929190829003018186803b158015610a1d57600080fd5b505afa158015610a31573d6000803e3d6000fd5b505050506040513d6020811015610a4757600080fd5b505161ffff16905060005b81811015610b2e576000836001600160a01b03166319b64015836040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b158015610aa057600080fd5b505afa158015610ab4573d6000803e3d6000fd5b505050506040513d6020811015610aca57600080fd5b505190506001600160a01b03808216908a1614610b25576060610aed828a61077f565b805190915015610b2357610b158a888881518110610b0757fe5b602002602001015183610df9565b9750505050505050506105de565b505b50600101610a52565b505050600101610954565b5060408051600080825260208201909252905b50949350505050565b606060008351118015610b69575060008251115b15610d8d57825182515b600082118015610b835750600081115b8015610bcc5750836001820381518110610b9957fe5b60200260200101516001600160a01b0316856001840381518110610bb957fe5b60200260200101516001600160a01b0316145b15610bde576000199182019101610b73565b606081830160010167ffffffffffffffff81118015610bfc57600080fd5b50604051908082528060200260200182016040528015610c26578160200160208202803683370190505b50905060005b838111610c7357868181518110610c3f57fe5b6020026020010151828281518110610c5357fe5b6001600160a01b0390921660209283029190910190910152600101610c2c565b50815b8015610cc357856001820381518110610c8b57fe5b6020026020010151828284510381518110610ca257fe5b6001600160a01b039092166020928302919091019091015260001901610c76565b506000805b8251811015610d7757600281015b60028206845103811015610d3057838181518110610cf057fe5b60200260200101516001600160a01b0316848381518110610d0d57fe5b60200260200101516001600160a01b03161415610d28578091505b600201610cd6565b50828181518110610d3d57fe5b6020026020010151838380600101945081518110610d5757fe5b6001600160a01b0390921660209283029190910190910152600101610cc8565b50610d828282610eef565b9450505050506105de565b60408051600080825260208201909252905b509392505050565b604080516001808252818301909252606091829190602080830190803683370190505090508281600081518110610dda57fe5b6001600160a01b03909216602092830291909101909101529050919050565b606080825160020167ffffffffffffffff81118015610e1757600080fd5b50604051908082528060200260200182016040528015610e41578160200160208202803683370190505b5090508481600081518110610e5257fe5b60200260200101906001600160a01b031690816001600160a01b0316815250508381600181518110610e8057fe5b60200260200101906001600160a01b031690816001600160a01b03168152505060005b8351811015610b4c57838181518110610eb857fe5b6020026020010151828260020181518110610ecf57fe5b6001600160a01b0390921660209283029190910190910152600101610ea3565b6060808267ffffffffffffffff81118015610f0957600080fd5b50604051908082528060200260200182016040528015610f33578160200160208202803683370190505b50905060005b83811015610d9f57848181518110610f4d57fe5b6020026020010151828281518110610f6157fe5b6001600160a01b0390921660209283029190910190910152600101610f3956fea26469706673582212208fc8a7bf8ce24f6ed7d1157da9bddf90b3c16820044c0c7e2b3cf0fe7c8e533b64736f6c634300060c0033",
|
|
"deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100cf5760003560e01c80637b1039991161008c578063b4a176d311610066578063b4a176d3146101f9578063d4ee1d9014610201578063e1c4c96614610209578063f2fde38b14610211576100cf565b80637b1039991461016b5780638da5cb5b14610173578063a1c421cd1461017b576100cf565b8063024c7ec7146100d45780632f167f05146100f55780632fe8a6ad1461011b57806349d10b641461013757806361cd756e1461013f57806379ba509714610163575b600080fd5b6100f3600480360360208110156100ea57600080fd5b50351515610237565b005b6100f36004803603602081101561010b57600080fd5b50356001600160a01b031661025d565b610123610287565b604080519115158252519081900360200190f35b6100f3610297565b61014761049f565b604080516001600160a01b039092168252519081900360200190f35b6100f36104ae565b610147610565565b610147610574565b6101a96004803603604081101561019157600080fd5b506001600160a01b0381358116916020013516610583565b60408051602080825283518183015283519192839290830191858101910280838360005b838110156101e55781810151838201526020016101cd565b505050509050019250505060405180910390f35b6100f36105e4565b610147610610565b61014761061f565b6100f36004803603602081101561022757600080fd5b50356001600160a01b031661062e565b61023f6106ac565b60038054911515600160a01b0260ff60a01b19909216919091179055565b6102656106ac565b600480546001600160a01b0319166001600160a01b0392909216919091179055565b600354600160a01b900460ff1681565b6000546001600160a01b03163314806102ba5750600354600160a01b900460ff16155b6102ff576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b600061031d6f436f6e7472616374526567697374727960801b610701565b6002549091506001600160a01b0380831691161480159061034657506001600160a01b03811615155b61038e576040805162461bcd60e51b81526020600482015260146024820152734552525f494e56414c49445f524547495354525960601b604482015290519081900360640190fd5b60006001600160a01b0316816001600160a01b031663bb34534c6f436f6e7472616374526567697374727960801b6040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b1580156103f057600080fd5b505afa158015610404573d6000803e3d6000fd5b505050506040513d602081101561041a57600080fd5b50516001600160a01b0316141561046f576040805162461bcd60e51b81526020600482015260146024820152734552525f494e56414c49445f524547495354525960601b604482015290519081900360640190fd5b60028054600380546001600160a01b038084166001600160a01b0319928316179092559091169216919091179055565b6003546001600160a01b031681565b6001546001600160a01b03163314610501576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b600154600080546040516001600160a01b0393841693909116917f343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a91a360018054600080546001600160a01b03199081166001600160a01b03841617909155169055565b6002546001600160a01b031681565b6000546001600160a01b031681565b606060006105b07f42616e636f72436f6e7665727465725265676973747279000000000000000000610701565b905060606105be858361077f565b905060606105cc858461077f565b90506105d88282610b55565b93505050505b92915050565b6105ec6106ac565b600354600280546001600160a01b0319166001600160a01b03909216919091179055565b6001546001600160a01b031681565b6004546001600160a01b031681565b6106366106ac565b6000546001600160a01b038281169116141561068a576040805162461bcd60e51b815260206004820152600e60248201526d22a9292fa9a0a6a2afa7aba722a960911b604482015290519081900360640190fd5b600180546001600160a01b0319166001600160a01b0392909216919091179055565b6000546001600160a01b031633146106ff576040805162461bcd60e51b815260206004820152601160248201527011549497d050d0d154d4d7d11153925151607a1b604482015290519081900360640190fd5b565b60025460408051632ecd14d360e21b81526004810184905290516000926001600160a01b03169163bb34534c916024808301926020929190829003018186803b15801561074d57600080fd5b505afa158015610761573d6000803e3d6000fd5b505050506040513d602081101561077757600080fd5b505192915050565b6004546060906001600160a01b03848116911614156107a8576107a183610da7565b90506105de565b6060826001600160a01b031663d8cced2a856040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060206040518083038186803b1580156107f757600080fd5b505afa15801561080b573d6000803e3d6000fd5b505050506040513d602081101561082157600080fd5b5051156108385761083184610da7565b9050610951565b826001600160a01b03166311839064856040518263ffffffff1660e01b815260040180826001600160a01b0316815260200191505060006040518083038186803b15801561088557600080fd5b505afa158015610899573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405260208110156108c257600080fd5b81019080805160405193929190846401000000008211156108e257600080fd5b9083019060208201858111156108f757600080fd5b825186602082028301116401000000008211171561091457600080fd5b82525081516020918201928201910280838360005b83811015610941578181015183820152602001610929565b5050505090500160405250505090505b60005b8151811015610b3957600082828151811061096b57fe5b60200260200101516001600160a01b0316638da5cb5b6040518163ffffffff1660e01b815260040160206040518083038186803b1580156109ab57600080fd5b505afa1580156109bf573d6000803e3d6000fd5b505050506040513d60208110156109d557600080fd5b5051604080516371f52bf360e01b815290519192506000916001600160a01b038416916371f52bf3916004808301926020929190829003018186803b158015610a1d57600080fd5b505afa158015610a31573d6000803e3d6000fd5b505050506040513d6020811015610a4757600080fd5b505161ffff16905060005b81811015610b2e576000836001600160a01b03166319b64015836040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b158015610aa057600080fd5b505afa158015610ab4573d6000803e3d6000fd5b505050506040513d6020811015610aca57600080fd5b505190506001600160a01b03808216908a1614610b25576060610aed828a61077f565b805190915015610b2357610b158a888881518110610b0757fe5b602002602001015183610df9565b9750505050505050506105de565b505b50600101610a52565b505050600101610954565b5060408051600080825260208201909252905b50949350505050565b606060008351118015610b69575060008251115b15610d8d57825182515b600082118015610b835750600081115b8015610bcc5750836001820381518110610b9957fe5b60200260200101516001600160a01b0316856001840381518110610bb957fe5b60200260200101516001600160a01b0316145b15610bde576000199182019101610b73565b606081830160010167ffffffffffffffff81118015610bfc57600080fd5b50604051908082528060200260200182016040528015610c26578160200160208202803683370190505b50905060005b838111610c7357868181518110610c3f57fe5b6020026020010151828281518110610c5357fe5b6001600160a01b0390921660209283029190910190910152600101610c2c565b50815b8015610cc357856001820381518110610c8b57fe5b6020026020010151828284510381518110610ca257fe5b6001600160a01b039092166020928302919091019091015260001901610c76565b506000805b8251811015610d7757600281015b60028206845103811015610d3057838181518110610cf057fe5b60200260200101516001600160a01b0316848381518110610d0d57fe5b60200260200101516001600160a01b03161415610d28578091505b600201610cd6565b50828181518110610d3d57fe5b6020026020010151838380600101945081518110610d5757fe5b6001600160a01b0390921660209283029190910190910152600101610cc8565b50610d828282610eef565b9450505050506105de565b60408051600080825260208201909252905b509392505050565b604080516001808252818301909252606091829190602080830190803683370190505090508281600081518110610dda57fe5b6001600160a01b03909216602092830291909101909101529050919050565b606080825160020167ffffffffffffffff81118015610e1757600080fd5b50604051908082528060200260200182016040528015610e41578160200160208202803683370190505b5090508481600081518110610e5257fe5b60200260200101906001600160a01b031690816001600160a01b0316815250508381600181518110610e8057fe5b60200260200101906001600160a01b031690816001600160a01b03168152505060005b8351811015610b4c57838181518110610eb857fe5b6020026020010151828260020181518110610ecf57fe5b6001600160a01b0390921660209283029190910190910152600101610ea3565b6060808267ffffffffffffffff81118015610f0957600080fd5b50604051908082528060200260200182016040528015610f33578160200160208202803683370190505b50905060005b83811015610d9f57848181518110610f4d57fe5b6020026020010151828281518110610f6157fe5b6001600160a01b0390921660209283029190910190910152600101610f3956fea26469706673582212208fc8a7bf8ce24f6ed7d1157da9bddf90b3c16820044c0c7e2b3cf0fe7c8e533b64736f6c634300060c0033",
|
|
"immutableReferences": {},
|
|
"sourceMap": "614:5672:1:-:0;;;893:90;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;893:90:1;619:5:57;:18;;-1:-1:-1;;;;;;619:18:57;627:10;619:18;;;893:90:1;;594:23:64;893:90:1;594:13:64;:23::i;:::-;-1:-1:-1;2122:8:56::1;:39:::0;;-1:-1:-1;;;;;2122:39:56;;::::1;-1:-1:-1::0;;;;;;2122:39:56;;::::1;::::0;::::1;::::0;;;2172:12:::1;:43:::0;;;;::::1;;::::0;;-1:-1:-1;614:5672:1;;692:128:64;-1:-1:-1;;;;;766:22:64;;758:54;;;;;-1:-1:-1;;;758:54:64;;;;;;;;;;;;;;;;;;;;;;;;;;;;692:128;:::o;614:5672:1:-;;;;;;;",
|
|
"deployedSourceMap": "614:5672:1:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3655:224:56;;;;;;;;;;;;;;;;-1:-1:-1;3655:224:56;;;;:::i;:::-;;1113:112:1;;;;;;;;;;;;;;;;-1:-1:-1;1113:112:1;-1:-1:-1;;;;;1113:112:1;;:::i;1333:38:56:-;;;:::i;:::-;;;;;;;;;;;;;;;;;;2300:925;;;:::i;1243:37::-;;;:::i;:::-;;;;-1:-1:-1;;;;;1243:37:56;;;;;;;;;;;;;;1422:217:57;;;:::i;1154:33:56:-;;;:::i;219:29:57:-;;;:::i;1543:446:1:-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;1543:446:1;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3304:137:56;;;:::i;255:23:57:-;;;:::i;700:30:1:-;;;:::i;1164:167:57:-;;;;;;;;;;;;;;;;-1:-1:-1;1164:167:57;-1:-1:-1;;;;;1164:167:57;;:::i;3655:224:56:-;726:12:57;:10;:12::i;:::-;3815:26:56::1;:56:::0;;;::::1;;-1:-1:-1::0;;;3815:56:56::1;-1:-1:-1::0;;;;3815:56:56;;::::1;::::0;;;::::1;::::0;;3655:224::o;1113:112:1:-;726:12:57;:10;:12::i;:::-;1191:11:1::1;:26:::0;;-1:-1:-1;;;;;;1191:26:1::1;-1:-1:-1::0;;;;;1191:26:1;;;::::1;::::0;;;::::1;::::0;;1113:112::o;1333:38:56:-;;;-1:-1:-1;;;1333:38:56;;;;;:::o;2300:925::-;2417:5;;-1:-1:-1;;;;;2417:5:56;2403:10;:19;;:50;;-1:-1:-1;2427:26:56;;-1:-1:-1;;;2427:26:56;;;;2426:27;2403:50;2395:80;;;;;-1:-1:-1;;;2395:80:56;;;;;;;;;;;;-1:-1:-1;;;2395:80:56;;;;;;;;;;;;;;;2530:29;2580:28;-1:-1:-1;;;2580:9:56;:28::i;:::-;2721:8;;2530:79;;-1:-1:-1;;;;;;2706:23:56;;;2721:8;;2706:23;;;;:61;;-1:-1:-1;;;;;;2733:34:56;;;;2706:61;2698:94;;;;;-1:-1:-1;;;2698:94:56;;;;;;;;;;;;-1:-1:-1;;;2698:94:56;;;;;;;;;;;;;;;2959:1;-1:-1:-1;;;;;2907:54:56;:11;-1:-1:-1;;;;;2907:21:56;;-1:-1:-1;;;2907:40:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;2907:40:56;-1:-1:-1;;;;;2907:54:56;;;2899:87;;;;;-1:-1:-1;;;2899:87:56;;;;;;;;;;;;-1:-1:-1;;;2899:87:56;;;;;;;;;;;;;;;3093:8;;;3078:12;:23;;-1:-1:-1;;;;;3093:8:56;;;-1:-1:-1;;;;;;3078:23:56;;;;;;;3195:22;;;;;;;;;;;2300:925::o;1243:37::-;;;-1:-1:-1;;;;;1243:37:56;;:::o;1422:217:57:-;1498:8;;-1:-1:-1;;;;;1498:8:57;1484:10;:22;1476:52;;;;;-1:-1:-1;;;1476:52:57;;;;;;;;;;;;-1:-1:-1;;;1476:52:57;;;;;;;;;;;;;;;1563:8;;;1556:5;;1544:28;;-1:-1:-1;;;;;1563:8:57;;;;1556:5;;;;1544:28;;;1591:8;;;;1583:16;;-1:-1:-1;;;;;;1583:16:57;;;-1:-1:-1;;;;;1591:8:57;;1583:16;;;;1610:21;;;1422:217::o;1154:33:56:-;;;-1:-1:-1;;;;;1154:33:56;;:::o;219:29:57:-;;;-1:-1:-1;;;;;219:29:57;;:::o;1543:446:1:-;1645:16;1674:36;1732:29;1742:18;1732:9;:29::i;:::-;1674:88;;1773:27;1803:40;1811:12;1825:17;1803:7;:40::i;:::-;1773:70;;1854:27;1884:40;1892:12;1906:17;1884:7;:40::i;:::-;1854:70;;1942:39;1958:10;1970;1942:15;:39::i;:::-;1935:46;;;;;1543:446;;;;;:::o;3304:137:56:-;726:12:57;:10;:12::i;:::-;3421::56::1;::::0;3410:8:::1;:23:::0;;-1:-1:-1;;;;;;3410:23:56::1;-1:-1:-1::0;;;;;3421:12:56;;::::1;3410:23:::0;;;::::1;::::0;;3304:137::o;255:23:57:-;;;-1:-1:-1;;;;;255:23:57;;:::o;700:30:1:-;;;-1:-1:-1;;;;;700:30:1;;:::o;1164:167:57:-;726:12;:10;:12::i;:::-;1268:5:::1;::::0;-1:-1:-1;;;;;1255:18:57;;::::1;1268:5:::0;::::1;1255:18;;1247:45;;;::::0;;-1:-1:-1;;;1247:45:57;;::::1;;::::0;::::1;::::0;::::1;::::0;;;;-1:-1:-1;;;1247:45:57;;;;;;;;;;;;;::::1;;1303:8;:20:::0;;-1:-1:-1;;;;;;1303:20:57::1;-1:-1:-1::0;;;;;1303:20:57;;;::::1;::::0;;;::::1;::::0;;1164:167::o;813:104::-;882:5;;-1:-1:-1;;;;;882:5:57;868:10;:19;860:49;;;;;-1:-1:-1;;;860:49:57;;;;;;;;;;;;-1:-1:-1;;;860:49:57;;;;;;;;;;;;;;;813:104::o;4077:133:56:-;4169:8;;:33;;;-1:-1:-1;;;4169:33:56;;;;;;;;;;4142:7;;-1:-1:-1;;;;;4169:8:56;;:18;;:33;;;;;;;;;;;;;;:8;:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;4169:33:56;;4077:133;-1:-1:-1;;4077:133:56:o;2311:1176:1:-;2452:11;;2409:16;;-1:-1:-1;;;;;2442:21:1;;;2452:11;;2442:21;2438:79;;;2485:32;2509:6;2485:15;:32::i;:::-;2478:39;;;;2438:79;2530:24;2569:18;-1:-1:-1;;;;;2569:27:1;;2605:6;2569:44;;;;;;;;;;;;;-1:-1:-1;;;;;2569:44:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;2569:44:1;2565:197;;;2638:32;2662:6;2638:15;:32::i;:::-;2628:42;;2565:197;;;2709:18;-1:-1:-1;;;;;2709:45:1;;2755:6;2709:53;;;;;;;;;;;;;-1:-1:-1;;;;;2709:53:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;2709:53:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;2709:53:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2699:63;;2565:197;2780:9;2775:669;2799:7;:14;2795:1;:18;2775:669;;;2835:20;2894:7;2902:1;2894:10;;;;;;;;;;;;;;-1:-1:-1;;;;;2877:34:1;;:36;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;2877:36:1;2960:31;;;-1:-1:-1;;;2960:31:1;;;;2877:36;;-1:-1:-1;2930:27:1;;-1:-1:-1;;;;;2960:29:1;;;;;:31;;;;;2877:36;;2960:31;;;;;;;:29;:31;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;2960:31:1;2930:61;;;-1:-1:-1;3011:9:1;3006:427;3030:19;3026:1;:23;3006:427;;;3075:26;3104:9;-1:-1:-1;;;;;3104:25:1;;3130:1;3104:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;3104:28:1;;-1:-1:-1;;;;;;3155:24:1;;;;;;;3151:267;;3204:21;3228:43;3236:14;3252:18;3228:7;:43::i;:::-;3298:11;;3204:67;;-1:-1:-1;3298:15:1;3294:104;;3347:51;3372:6;3381:7;3389:1;3381:10;;;;;;;;;;;;;;3393:4;3347:16;:51::i;:::-;3340:58;;;;;;;;;;;3294:104;3151:267;;-1:-1:-1;3051:3:1;;3006:427;;;-1:-1:-1;;;2815:3:1;;2775:669;;;-1:-1:-1;3463:16:1;;;3477:1;3463:16;;;;;;;;;;;-1:-1:-1;3456:23:1;2311:1176;-1:-1:-1;;;;2311:1176:1:o;3730:1114::-;3837:16;3891:1;3870:11;:18;:22;:48;;;;;3917:1;3896:11;:18;:22;3870:48;3866:935;;;3947:18;;3992;;4025:127;4036:1;4032;:5;:14;;;;;4045:1;4041;:5;4032:14;:58;;;;;4072:11;4088:1;4084;:5;4072:18;;;;;;;;;;;;;;-1:-1:-1;;;;;4050:40:1;:11;4066:1;4062;:5;4050:18;;;;;;;;;;;;;;-1:-1:-1;;;;;4050:40:1;;4032:58;4025:127;;;-1:-1:-1;;4111:3:1;;;;4133;4025:127;;;4168:21;4210:1;4206;:5;4214:1;4206:9;4192:24;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;4192:24:1;;4168:48;;4236:9;4231:74;4256:1;4251;:6;4231:74;;4291:11;4303:1;4291:14;;;;;;;;;;;;;;4281:4;4286:1;4281:7;;;;;;;;-1:-1:-1;;;;;4281:24:1;;;:7;;;;;;;;;;;:24;4259:3;;4231:74;;;-1:-1:-1;4337:1:1;4320:91;4340:5;;4320:91;;4393:11;4409:1;4405;:5;4393:18;;;;;;;;;;;;;;4369:4;4388:1;4374:4;:11;:15;4369:21;;;;;;;;-1:-1:-1;;;;;4369:42:1;;;:21;;;;;;;;;;;:42;-1:-1:-1;;4347:3:1;4320:91;;;;4428:14;4466:9;4461:276;4485:4;:11;4481:1;:15;4461:276;;;4546:1;4542:5;;4525:154;4571:1;4567;:5;4553:4;:11;:19;4549:1;:23;4525:154;;;4620:4;4625:1;4620:7;;;;;;;;;;;;;;-1:-1:-1;;;;;4609:18:1;:4;4614:1;4609:7;;;;;;;;;;;;;;-1:-1:-1;;;;;4609:18:1;;4605:54;;;4658:1;4654:5;;4605:54;4579:1;4574:6;4525:154;;;;4714:4;4719:1;4714:7;;;;;;;;;;;;;;4697:4;4702:8;;;;;;4697:14;;;;;;;;-1:-1:-1;;;;;4697:24:1;;;:14;;;;;;;;;;;:24;4503:1;4498:6;4461:276;;;;4760:29;4776:4;4782:6;4760:15;:29::i;:::-;4753:36;;;;;;;;3866:935;4820:16;;;4834:1;4820:16;;;;;;;;;;;-1:-1:-1;4813:23:1;3730:1114;-1:-1:-1;;;3730:1114:1:o;5004:190::-;5120:16;;;5134:1;5120:16;;;;;;;;;5066;;;;5120;;;;;;;;;;;;-1:-1:-1;5120:16:1;5095:41;;5158:5;5147;5153:1;5147:8;;;;;;;;-1:-1:-1;;;;;5147:16:1;;;:8;;;;;;;;;;;:16;5181:5;-1:-1:-1;5004:190:1;;;:::o;5437:370::-;5542:16;5571:22;5614:6;:13;5610:1;:17;5596:32;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;5596:32:1;;5571:57;;5650:6;5639:5;5645:1;5639:8;;;;;;;;;;;;;:17;-1:-1:-1;;;;;5639:17:1;;;-1:-1:-1;;;;;5639:17:1;;;;;5678:6;5667:5;5673:1;5667:8;;;;;;;;;;;;;:17;-1:-1:-1;;;;;5667:17:1;;;-1:-1:-1;;;;;5667:17:1;;;;;5700:9;5695:81;5719:6;:13;5715:1;:17;5695:81;;;5767:6;5774:1;5767:9;;;;;;;;;;;;;;5752:5;5762:1;5758;:5;5752:12;;;;;;;;-1:-1:-1;;;;;5752:24:1;;;:12;;;;;;;;;;;:24;5734:3;;5695:81;;6005:278;6094:16;6123:22;6162:7;6148:22;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;6148:22:1;;6123:47;;6186:9;6181:71;6205:7;6201:1;:11;6181:71;;;6243:6;6250:1;6243:9;;;;;;;;;;;;;;6232:5;6238:1;6232:8;;;;;;;;-1:-1:-1;;;;;6232:20:1;;;:8;;;;;;;;;;;:20;6214:3;;6181:71;",
|
|
"source": "// SPDX-License-Identifier: SEE LICENSE IN LICENSE\r\npragma solidity 0.6.12;\r\nimport \"./IConversionPathFinder.sol\";\r\nimport \"./utility/ContractRegistryClient.sol\";\r\nimport \"./converter/interfaces/IConverter.sol\";\r\nimport \"./converter/interfaces/IConverterAnchor.sol\";\r\nimport \"./converter/interfaces/IConverterRegistry.sol\";\r\n\r\n/**\r\n * @dev The ConversionPathFinder contract allows generating a conversion path between any token pair in the Bancor Network.\r\n * The path can then be used in various functions in the BancorNetwork contract.\r\n *\r\n * See the BancorNetwork contract for conversion path format.\r\n*/\r\ncontract ConversionPathFinder is IConversionPathFinder, ContractRegistryClient {\r\n IERC20Token public anchorToken;\r\n\r\n /**\r\n * @dev initializes a new ConversionPathFinder instance\r\n *\r\n * @param _registry address of a contract registry contract\r\n */\r\n constructor(IContractRegistry _registry) ContractRegistryClient(_registry) public {\r\n }\r\n\r\n /**\r\n * @dev updates the anchor token\r\n *\r\n * @param _anchorToken address of the anchor token\r\n */\r\n function setAnchorToken(IERC20Token _anchorToken) public ownerOnly {\r\n anchorToken = _anchorToken;\r\n }\r\n\r\n /**\r\n * @dev generates a conversion path between a given pair of tokens in the Bancor Network\r\n *\r\n * @param _sourceToken address of the source token\r\n * @param _targetToken address of the target token\r\n *\r\n * @return a path from the source token to the target token\r\n */\r\n function findPath(IERC20Token _sourceToken, IERC20Token _targetToken) external view override returns (address[] memory) {\r\n IConverterRegistry converterRegistry = IConverterRegistry(addressOf(CONVERTER_REGISTRY));\r\n address[] memory sourcePath = getPath(_sourceToken, converterRegistry);\r\n address[] memory targetPath = getPath(_targetToken, converterRegistry);\r\n return getShortestPath(sourcePath, targetPath);\r\n }\r\n\r\n /**\r\n * @dev generates a conversion path between a given token and the anchor token\r\n *\r\n * @param _token address of the token\r\n * @param _converterRegistry address of the converter registry\r\n *\r\n * @return a path from the input token to the anchor token\r\n */\r\n function getPath(IERC20Token _token, IConverterRegistry _converterRegistry) private view returns (address[] memory) {\r\n if (_token == anchorToken)\r\n return getInitialArray(address(_token));\r\n\r\n address[] memory anchors;\r\n if (_converterRegistry.isAnchor(address(_token)))\r\n anchors = getInitialArray(address(_token));\r\n else\r\n anchors = _converterRegistry.getConvertibleTokenAnchors(_token);\r\n\r\n for (uint256 n = 0; n < anchors.length; n++) {\r\n IConverter converter = IConverter(payable(IConverterAnchor(anchors[n]).owner()));\r\n uint256 connectorTokenCount = converter.connectorTokenCount();\r\n for (uint256 i = 0; i < connectorTokenCount; i++) {\r\n IERC20Token connectorToken = converter.connectorTokens(i);\r\n if (connectorToken != _token) {\r\n address[] memory path = getPath(connectorToken, _converterRegistry);\r\n if (path.length > 0)\r\n return getExtendedArray(address(_token), anchors[n], path);\r\n }\r\n }\r\n }\r\n\r\n return new address[](0);\r\n }\r\n\r\n /**\r\n * @dev merges two paths with a common suffix into one\r\n *\r\n * @param _sourcePath address of the source path\r\n * @param _targetPath address of the target path\r\n *\r\n * @return merged path\r\n */\r\n function getShortestPath(address[] memory _sourcePath, address[] memory _targetPath) private pure returns (address[] memory) {\r\n if (_sourcePath.length > 0 && _targetPath.length > 0) {\r\n uint256 i = _sourcePath.length;\r\n uint256 j = _targetPath.length;\r\n while (i > 0 && j > 0 && _sourcePath[i - 1] == _targetPath[j - 1]) {\r\n i--;\r\n j--;\r\n }\r\n\r\n address[] memory path = new address[](i + j + 1);\r\n for (uint256 m = 0; m <= i; m++)\r\n path[m] = _sourcePath[m];\r\n for (uint256 n = j; n > 0; n--)\r\n path[path.length - n] = _targetPath[n - 1];\r\n\r\n uint256 length = 0;\r\n for (uint256 p = 0; p < path.length; p += 1) {\r\n for (uint256 q = p + 2; q < path.length - p % 2; q += 2) {\r\n if (path[p] == path[q])\r\n p = q;\r\n }\r\n path[length++] = path[p];\r\n }\r\n\r\n return getPartialArray(path, length);\r\n }\r\n\r\n return new address[](0);\r\n }\r\n\r\n /**\r\n * @dev creates a new array containing a single item\r\n *\r\n * @param _item item\r\n *\r\n * @return initial array\r\n */\r\n function getInitialArray(address _item) private pure returns (address[] memory) {\r\n address[] memory array = new address[](1);\r\n array[0] = _item;\r\n return array;\r\n }\r\n\r\n /**\r\n * @dev prepends two items to the beginning of an array\r\n *\r\n * @param _item0 first item\r\n * @param _item1 second item\r\n * @param _array initial array\r\n *\r\n * @return extended array\r\n */\r\n function getExtendedArray(address _item0, address _item1, address[] memory _array) private pure returns (address[] memory) {\r\n address[] memory array = new address[](2 + _array.length);\r\n array[0] = _item0;\r\n array[1] = _item1;\r\n for (uint256 i = 0; i < _array.length; i++)\r\n array[2 + i] = _array[i];\r\n return array;\r\n }\r\n\r\n /**\r\n * @dev extracts the prefix of a given array\r\n *\r\n * @param _array given array\r\n * @param _length prefix length\r\n *\r\n * @return partial array\r\n */\r\n function getPartialArray(address[] memory _array, uint256 _length) private pure returns (address[] memory) {\r\n address[] memory array = new address[](_length);\r\n for (uint256 i = 0; i < _length; i++)\r\n array[i] = _array[i];\r\n return array;\r\n }\r\n}\r\n",
|
|
"sourcePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/ConversionPathFinder.sol",
|
|
"ast": {
|
|
"absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/ConversionPathFinder.sol",
|
|
"exportedSymbols": {
|
|
"ConversionPathFinder": [
|
|
2532
|
|
]
|
|
},
|
|
"id": 2533,
|
|
"license": "SEE LICENSE IN LICENSE",
|
|
"nodeType": "SourceUnit",
|
|
"nodes": [
|
|
{
|
|
"id": 1978,
|
|
"literals": [
|
|
"solidity",
|
|
"0.6",
|
|
".12"
|
|
],
|
|
"nodeType": "PragmaDirective",
|
|
"src": "52:23:1"
|
|
},
|
|
{
|
|
"absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/IConversionPathFinder.sol",
|
|
"file": "./IConversionPathFinder.sol",
|
|
"id": 1979,
|
|
"nodeType": "ImportDirective",
|
|
"scope": 2533,
|
|
"sourceUnit": 2547,
|
|
"src": "77:37:1",
|
|
"symbolAliases": [],
|
|
"unitAlias": ""
|
|
},
|
|
{
|
|
"absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/ContractRegistryClient.sol",
|
|
"file": "./utility/ContractRegistryClient.sol",
|
|
"id": 1980,
|
|
"nodeType": "ImportDirective",
|
|
"scope": 2533,
|
|
"sourceUnit": 21720,
|
|
"src": "116:46:1",
|
|
"symbolAliases": [],
|
|
"unitAlias": ""
|
|
},
|
|
{
|
|
"absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IConverter.sol",
|
|
"file": "./converter/interfaces/IConverter.sol",
|
|
"id": 1981,
|
|
"nodeType": "ImportDirective",
|
|
"scope": 2533,
|
|
"sourceUnit": 13341,
|
|
"src": "164:47:1",
|
|
"symbolAliases": [],
|
|
"unitAlias": ""
|
|
},
|
|
{
|
|
"absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IConverterAnchor.sol",
|
|
"file": "./converter/interfaces/IConverterAnchor.sol",
|
|
"id": 1982,
|
|
"nodeType": "ImportDirective",
|
|
"scope": 2533,
|
|
"sourceUnit": 13350,
|
|
"src": "213:53:1",
|
|
"symbolAliases": [],
|
|
"unitAlias": ""
|
|
},
|
|
{
|
|
"absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IConverterRegistry.sol",
|
|
"file": "./converter/interfaces/IConverterRegistry.sol",
|
|
"id": 1983,
|
|
"nodeType": "ImportDirective",
|
|
"scope": 2533,
|
|
"sourceUnit": 13502,
|
|
"src": "268:55:1",
|
|
"symbolAliases": [],
|
|
"unitAlias": ""
|
|
},
|
|
{
|
|
"abstract": false,
|
|
"baseContracts": [
|
|
{
|
|
"arguments": null,
|
|
"baseName": {
|
|
"contractScope": null,
|
|
"id": 1985,
|
|
"name": "IConversionPathFinder",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 2546,
|
|
"src": "647:21:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConversionPathFinder_$2546",
|
|
"typeString": "contract IConversionPathFinder"
|
|
}
|
|
},
|
|
"id": 1986,
|
|
"nodeType": "InheritanceSpecifier",
|
|
"src": "647:21:1"
|
|
},
|
|
{
|
|
"arguments": null,
|
|
"baseName": {
|
|
"contractScope": null,
|
|
"id": 1987,
|
|
"name": "ContractRegistryClient",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 21719,
|
|
"src": "670:22:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_ContractRegistryClient_$21719",
|
|
"typeString": "contract ContractRegistryClient"
|
|
}
|
|
},
|
|
"id": 1988,
|
|
"nodeType": "InheritanceSpecifier",
|
|
"src": "670:22:1"
|
|
}
|
|
],
|
|
"contractDependencies": [
|
|
2546,
|
|
21719,
|
|
21818,
|
|
22661,
|
|
22847
|
|
],
|
|
"contractKind": "contract",
|
|
"documentation": {
|
|
"id": 1984,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "327:285:1",
|
|
"text": " @dev The ConversionPathFinder contract allows generating a conversion path between any token pair in the Bancor Network.\n The path can then be used in various functions in the BancorNetwork contract.\n See the BancorNetwork contract for conversion path format."
|
|
},
|
|
"fullyImplemented": true,
|
|
"id": 2532,
|
|
"linearizedBaseContracts": [
|
|
2532,
|
|
21719,
|
|
22661,
|
|
21818,
|
|
22847,
|
|
2546
|
|
],
|
|
"name": "ConversionPathFinder",
|
|
"nodeType": "ContractDefinition",
|
|
"nodes": [
|
|
{
|
|
"constant": false,
|
|
"functionSelector": "e1c4c966",
|
|
"id": 1990,
|
|
"mutability": "mutable",
|
|
"name": "anchorToken",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2532,
|
|
"src": "700:30:1",
|
|
"stateVariable": true,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 1989,
|
|
"name": "IERC20Token",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 21127,
|
|
"src": "700:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 1999,
|
|
"nodeType": "Block",
|
|
"src": "975:8:1",
|
|
"statements": []
|
|
},
|
|
"documentation": {
|
|
"id": 1991,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "739:148:1",
|
|
"text": " @dev initializes a new ConversionPathFinder instance\n @param _registry address of a contract registry contract"
|
|
},
|
|
"id": 2000,
|
|
"implemented": true,
|
|
"kind": "constructor",
|
|
"modifiers": [
|
|
{
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1996,
|
|
"name": "_registry",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1993,
|
|
"src": "957:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IContractRegistry_$22831",
|
|
"typeString": "contract IContractRegistry"
|
|
}
|
|
}
|
|
],
|
|
"id": 1997,
|
|
"modifierName": {
|
|
"argumentTypes": null,
|
|
"id": 1995,
|
|
"name": "ContractRegistryClient",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 21719,
|
|
"src": "934:22:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_contract$_ContractRegistryClient_$21719_$",
|
|
"typeString": "type(contract ContractRegistryClient)"
|
|
}
|
|
},
|
|
"nodeType": "ModifierInvocation",
|
|
"src": "934:33:1"
|
|
}
|
|
],
|
|
"name": "",
|
|
"nodeType": "FunctionDefinition",
|
|
"overrides": null,
|
|
"parameters": {
|
|
"id": 1994,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1993,
|
|
"mutability": "mutable",
|
|
"name": "_registry",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2000,
|
|
"src": "905:27:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IContractRegistry_$22831",
|
|
"typeString": "contract IContractRegistry"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 1992,
|
|
"name": "IContractRegistry",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 22831,
|
|
"src": "905:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IContractRegistry_$22831",
|
|
"typeString": "contract IContractRegistry"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "904:29:1"
|
|
},
|
|
"returnParameters": {
|
|
"id": 1998,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [],
|
|
"src": "975:0:1"
|
|
},
|
|
"scope": 2532,
|
|
"src": "893:90:1",
|
|
"stateMutability": "nonpayable",
|
|
"virtual": false,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2012,
|
|
"nodeType": "Block",
|
|
"src": "1180:45:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2010,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2008,
|
|
"name": "anchorToken",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1990,
|
|
"src": "1191:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2009,
|
|
"name": "_anchorToken",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2003,
|
|
"src": "1205:12:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"src": "1191:26:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"id": 2011,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "1191:26:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 2001,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "991:116:1",
|
|
"text": " @dev updates the anchor token\n @param _anchorToken address of the anchor token"
|
|
},
|
|
"functionSelector": "2f167f05",
|
|
"id": 2013,
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [
|
|
{
|
|
"arguments": null,
|
|
"id": 2006,
|
|
"modifierName": {
|
|
"argumentTypes": null,
|
|
"id": 2005,
|
|
"name": "ownerOnly",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 21754,
|
|
"src": "1170:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_modifier$__$",
|
|
"typeString": "modifier ()"
|
|
}
|
|
},
|
|
"nodeType": "ModifierInvocation",
|
|
"src": "1170:9:1"
|
|
}
|
|
],
|
|
"name": "setAnchorToken",
|
|
"nodeType": "FunctionDefinition",
|
|
"overrides": null,
|
|
"parameters": {
|
|
"id": 2004,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2003,
|
|
"mutability": "mutable",
|
|
"name": "_anchorToken",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2013,
|
|
"src": "1137:24:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 2002,
|
|
"name": "IERC20Token",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 21127,
|
|
"src": "1137:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "1136:26:1"
|
|
},
|
|
"returnParameters": {
|
|
"id": 2007,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [],
|
|
"src": "1180:0:1"
|
|
},
|
|
"scope": 2532,
|
|
"src": "1113:112:1",
|
|
"stateMutability": "nonpayable",
|
|
"virtual": false,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"baseFunctions": [
|
|
2545
|
|
],
|
|
"body": {
|
|
"id": 2058,
|
|
"nodeType": "Block",
|
|
"src": "1663:326:1",
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
2026
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2026,
|
|
"mutability": "mutable",
|
|
"name": "converterRegistry",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2058,
|
|
"src": "1674:36:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 2025,
|
|
"name": "IConverterRegistry",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 13501,
|
|
"src": "1674:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2032,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2029,
|
|
"name": "CONVERTER_REGISTRY",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 21545,
|
|
"src": "1742:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes32",
|
|
"typeString": "bytes32"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_bytes32",
|
|
"typeString": "bytes32"
|
|
}
|
|
],
|
|
"id": 2028,
|
|
"name": "addressOf",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 21718,
|
|
"src": "1732:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$",
|
|
"typeString": "function (bytes32) view returns (address)"
|
|
}
|
|
},
|
|
"id": 2030,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1732:29:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
],
|
|
"id": 2027,
|
|
"name": "IConverterRegistry",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 13501,
|
|
"src": "1713:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_contract$_IConverterRegistry_$13501_$",
|
|
"typeString": "type(contract IConverterRegistry)"
|
|
}
|
|
},
|
|
"id": 2031,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1713:49:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "1674:88:1"
|
|
},
|
|
{
|
|
"assignments": [
|
|
2037
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2037,
|
|
"mutability": "mutable",
|
|
"name": "sourcePath",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2058,
|
|
"src": "1773:27:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2035,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1773:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2036,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "1773:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2042,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2039,
|
|
"name": "_sourceToken",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2016,
|
|
"src": "1811:12:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2040,
|
|
"name": "converterRegistry",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2026,
|
|
"src": "1825:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
],
|
|
"id": 2038,
|
|
"name": "getPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2202,
|
|
"src": "1803:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_view$_t_contract$_IERC20Token_$21127_$_t_contract$_IConverterRegistry_$13501_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (contract IERC20Token,contract IConverterRegistry) view returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2041,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1803:40:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "1773:70:1"
|
|
},
|
|
{
|
|
"assignments": [
|
|
2047
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2047,
|
|
"mutability": "mutable",
|
|
"name": "targetPath",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2058,
|
|
"src": "1854:27:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2045,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1854:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2046,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "1854:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2052,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2049,
|
|
"name": "_targetToken",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2018,
|
|
"src": "1892:12:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2050,
|
|
"name": "converterRegistry",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2026,
|
|
"src": "1906:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
],
|
|
"id": 2048,
|
|
"name": "getPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2202,
|
|
"src": "1884:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_view$_t_contract$_IERC20Token_$21127_$_t_contract$_IConverterRegistry_$13501_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (contract IERC20Token,contract IConverterRegistry) view returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2051,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1884:40:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "1854:70:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2054,
|
|
"name": "sourcePath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2037,
|
|
"src": "1958:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2055,
|
|
"name": "targetPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2047,
|
|
"src": "1970:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
],
|
|
"id": 2053,
|
|
"name": "getShortestPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2392,
|
|
"src": "1942:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_array$_t_address_$dyn_memory_ptr_$_t_array$_t_address_$dyn_memory_ptr_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (address[] memory,address[] memory) pure returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2056,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1942:39:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2024,
|
|
"id": 2057,
|
|
"nodeType": "Return",
|
|
"src": "1935:46:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 2014,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "1233:304:1",
|
|
"text": " @dev generates a conversion path between a given pair of tokens in the Bancor Network\n @param _sourceToken address of the source token\n @param _targetToken address of the target token\n @return a path from the source token to the target token"
|
|
},
|
|
"functionSelector": "a1c421cd",
|
|
"id": 2059,
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "findPath",
|
|
"nodeType": "FunctionDefinition",
|
|
"overrides": {
|
|
"id": 2020,
|
|
"nodeType": "OverrideSpecifier",
|
|
"overrides": [],
|
|
"src": "1627:8:1"
|
|
},
|
|
"parameters": {
|
|
"id": 2019,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2016,
|
|
"mutability": "mutable",
|
|
"name": "_sourceToken",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2059,
|
|
"src": "1561:24:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 2015,
|
|
"name": "IERC20Token",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 21127,
|
|
"src": "1561:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 2018,
|
|
"mutability": "mutable",
|
|
"name": "_targetToken",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2059,
|
|
"src": "1587:24:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 2017,
|
|
"name": "IERC20Token",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 21127,
|
|
"src": "1587:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "1560:52:1"
|
|
},
|
|
"returnParameters": {
|
|
"id": 2024,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2023,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2059,
|
|
"src": "1645:16:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2021,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1645:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2022,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "1645:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "1644:18:1"
|
|
},
|
|
"scope": 2532,
|
|
"src": "1543:446:1",
|
|
"stateMutability": "view",
|
|
"virtual": false,
|
|
"visibility": "external"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2201,
|
|
"nodeType": "Block",
|
|
"src": "2427:1060:1",
|
|
"statements": [
|
|
{
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
"id": 2072,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2070,
|
|
"name": "_token",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2062,
|
|
"src": "2442:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "==",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2071,
|
|
"name": "anchorToken",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1990,
|
|
"src": "2452:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"src": "2442:21:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"falseBody": null,
|
|
"id": 2080,
|
|
"nodeType": "IfStatement",
|
|
"src": "2438:79:1",
|
|
"trueBody": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2076,
|
|
"name": "_token",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2062,
|
|
"src": "2509:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
],
|
|
"id": 2075,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "ElementaryTypeNameExpression",
|
|
"src": "2501:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_address_$",
|
|
"typeString": "type(address)"
|
|
},
|
|
"typeName": {
|
|
"id": 2074,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2501:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": null,
|
|
"typeString": null
|
|
}
|
|
}
|
|
},
|
|
"id": 2077,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2501:15:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
],
|
|
"id": 2073,
|
|
"name": "getInitialArray",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2421,
|
|
"src": "2485:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_address_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (address) pure returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2078,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2485:32:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2069,
|
|
"id": 2079,
|
|
"nodeType": "Return",
|
|
"src": "2478:39:1"
|
|
}
|
|
},
|
|
{
|
|
"assignments": [
|
|
2085
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2085,
|
|
"mutability": "mutable",
|
|
"name": "anchors",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2201,
|
|
"src": "2530:24:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2083,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2530:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2084,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "2530:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2086,
|
|
"initialValue": null,
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "2530:24:1"
|
|
},
|
|
{
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2091,
|
|
"name": "_token",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2062,
|
|
"src": "2605:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
],
|
|
"id": 2090,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "ElementaryTypeNameExpression",
|
|
"src": "2597:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_address_$",
|
|
"typeString": "type(address)"
|
|
},
|
|
"typeName": {
|
|
"id": 2089,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2597:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": null,
|
|
"typeString": null
|
|
}
|
|
}
|
|
},
|
|
"id": 2092,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2597:15:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2087,
|
|
"name": "_converterRegistry",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2064,
|
|
"src": "2569:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
},
|
|
"id": 2088,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "isAnchor",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 13417,
|
|
"src": "2569:27:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$",
|
|
"typeString": "function (address) view external returns (bool)"
|
|
}
|
|
},
|
|
"id": 2093,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2569:44:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"falseBody": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2108,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2103,
|
|
"name": "anchors",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2085,
|
|
"src": "2699:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2106,
|
|
"name": "_token",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2062,
|
|
"src": "2755:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2104,
|
|
"name": "_converterRegistry",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2064,
|
|
"src": "2709:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
},
|
|
"id": 2105,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "getConvertibleTokenAnchors",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 13482,
|
|
"src": "2709:45:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_external_view$_t_contract$_IERC20Token_$21127_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (contract IERC20Token) view external returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2107,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2709:53:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"src": "2699:63:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2109,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "2699:63:1"
|
|
},
|
|
"id": 2110,
|
|
"nodeType": "IfStatement",
|
|
"src": "2565:197:1",
|
|
"trueBody": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2101,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2094,
|
|
"name": "anchors",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2085,
|
|
"src": "2628:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2098,
|
|
"name": "_token",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2062,
|
|
"src": "2662:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
],
|
|
"id": 2097,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "ElementaryTypeNameExpression",
|
|
"src": "2654:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_address_$",
|
|
"typeString": "type(address)"
|
|
},
|
|
"typeName": {
|
|
"id": 2096,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2654:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": null,
|
|
"typeString": null
|
|
}
|
|
}
|
|
},
|
|
"id": 2099,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2654:15:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
],
|
|
"id": 2095,
|
|
"name": "getInitialArray",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2421,
|
|
"src": "2638:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_address_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (address) pure returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2100,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2638:32:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"src": "2628:42:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2102,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "2628:42:1"
|
|
}
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2193,
|
|
"nodeType": "Block",
|
|
"src": "2820:624:1",
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
2123
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2123,
|
|
"mutability": "mutable",
|
|
"name": "converter",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2193,
|
|
"src": "2835:20:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverter_$13340",
|
|
"typeString": "contract IConverter"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 2122,
|
|
"name": "IConverter",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 13340,
|
|
"src": "2835:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverter_$13340",
|
|
"typeString": "contract IConverter"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2136,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"arguments": [],
|
|
"expression": {
|
|
"argumentTypes": [],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2128,
|
|
"name": "anchors",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2085,
|
|
"src": "2894:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2130,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2129,
|
|
"name": "n",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2112,
|
|
"src": "2902:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2894:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
],
|
|
"id": 2127,
|
|
"name": "IConverterAnchor",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 13349,
|
|
"src": "2877:16:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_contract$_IConverterAnchor_$13349_$",
|
|
"typeString": "type(contract IConverterAnchor)"
|
|
}
|
|
},
|
|
"id": 2131,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2877:28:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterAnchor_$13349",
|
|
"typeString": "contract IConverterAnchor"
|
|
}
|
|
},
|
|
"id": 2132,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "owner",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 22838,
|
|
"src": "2877:34:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_external_view$__$returns$_t_address_$",
|
|
"typeString": "function () view external returns (address)"
|
|
}
|
|
},
|
|
"id": 2133,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2877:36:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
],
|
|
"id": 2126,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "ElementaryTypeNameExpression",
|
|
"src": "2869:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_address_payable_$",
|
|
"typeString": "type(address payable)"
|
|
},
|
|
"typeName": {
|
|
"id": 2125,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2869:8:1",
|
|
"stateMutability": "payable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": null,
|
|
"typeString": null
|
|
}
|
|
}
|
|
},
|
|
"id": 2134,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2869:45:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address_payable",
|
|
"typeString": "address payable"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address_payable",
|
|
"typeString": "address payable"
|
|
}
|
|
],
|
|
"id": 2124,
|
|
"name": "IConverter",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 13340,
|
|
"src": "2858:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_contract$_IConverter_$13340_$",
|
|
"typeString": "type(contract IConverter)"
|
|
}
|
|
},
|
|
"id": 2135,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2858:57:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverter_$13340",
|
|
"typeString": "contract IConverter"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "2835:80:1"
|
|
},
|
|
{
|
|
"assignments": [
|
|
2138
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2138,
|
|
"mutability": "mutable",
|
|
"name": "connectorTokenCount",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2193,
|
|
"src": "2930:27:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2137,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2930:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2142,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [],
|
|
"expression": {
|
|
"argumentTypes": [],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2139,
|
|
"name": "converter",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2123,
|
|
"src": "2960:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverter_$13340",
|
|
"typeString": "contract IConverter"
|
|
}
|
|
},
|
|
"id": 2140,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "connectorTokenCount",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 13339,
|
|
"src": "2960:29:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_external_view$__$returns$_t_uint16_$",
|
|
"typeString": "function () view external returns (uint16)"
|
|
}
|
|
},
|
|
"id": 2141,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2960:31:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint16",
|
|
"typeString": "uint16"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "2930:61:1"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2191,
|
|
"nodeType": "Block",
|
|
"src": "3056:377:1",
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
2154
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2154,
|
|
"mutability": "mutable",
|
|
"name": "connectorToken",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2191,
|
|
"src": "3075:26:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 2153,
|
|
"name": "IERC20Token",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 21127,
|
|
"src": "3075:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2159,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2157,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2144,
|
|
"src": "3130:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2155,
|
|
"name": "converter",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2123,
|
|
"src": "3104:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverter_$13340",
|
|
"typeString": "contract IConverter"
|
|
}
|
|
},
|
|
"id": 2156,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "connectorTokens",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 13334,
|
|
"src": "3104:25:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_contract$_IERC20Token_$21127_$",
|
|
"typeString": "function (uint256) view external returns (contract IERC20Token)"
|
|
}
|
|
},
|
|
"id": 2158,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "3104:28:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "3075:57:1"
|
|
},
|
|
{
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
"id": 2162,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2160,
|
|
"name": "connectorToken",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2154,
|
|
"src": "3155:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "!=",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2161,
|
|
"name": "_token",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2062,
|
|
"src": "3173:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"src": "3155:24:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"falseBody": null,
|
|
"id": 2190,
|
|
"nodeType": "IfStatement",
|
|
"src": "3151:267:1",
|
|
"trueBody": {
|
|
"id": 2189,
|
|
"nodeType": "Block",
|
|
"src": "3181:237:1",
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
2167
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2167,
|
|
"mutability": "mutable",
|
|
"name": "path",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2189,
|
|
"src": "3204:21:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2165,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3204:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2166,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "3204:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2172,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2169,
|
|
"name": "connectorToken",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2154,
|
|
"src": "3236:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2170,
|
|
"name": "_converterRegistry",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2064,
|
|
"src": "3252:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
],
|
|
"id": 2168,
|
|
"name": "getPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2202,
|
|
"src": "3228:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_view$_t_contract$_IERC20Token_$21127_$_t_contract$_IConverterRegistry_$13501_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (contract IERC20Token,contract IConverterRegistry) view returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2171,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "3228:43:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "3204:67:1"
|
|
},
|
|
{
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2176,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2173,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2167,
|
|
"src": "3298:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2174,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "3298:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": ">",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2175,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "3312:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"src": "3298:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"falseBody": null,
|
|
"id": 2188,
|
|
"nodeType": "IfStatement",
|
|
"src": "3294:104:1",
|
|
"trueBody": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2180,
|
|
"name": "_token",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2062,
|
|
"src": "3372:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
],
|
|
"id": 2179,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "ElementaryTypeNameExpression",
|
|
"src": "3364:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_address_$",
|
|
"typeString": "type(address)"
|
|
},
|
|
"typeName": {
|
|
"id": 2178,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3364:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": null,
|
|
"typeString": null
|
|
}
|
|
}
|
|
},
|
|
"id": 2181,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "3364:15:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2182,
|
|
"name": "anchors",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2085,
|
|
"src": "3381:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2184,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2183,
|
|
"name": "n",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2112,
|
|
"src": "3389:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "3381:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2185,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2167,
|
|
"src": "3393:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
],
|
|
"id": 2177,
|
|
"name": "getExtendedArray",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2486,
|
|
"src": "3347:16:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_address_$_t_address_$_t_array$_t_address_$dyn_memory_ptr_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (address,address,address[] memory) pure returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2186,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "3347:51:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2069,
|
|
"id": 2187,
|
|
"nodeType": "Return",
|
|
"src": "3340:58:1"
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2149,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2147,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2144,
|
|
"src": "3026:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "<",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2148,
|
|
"name": "connectorTokenCount",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2138,
|
|
"src": "3030:19:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "3026:23:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2192,
|
|
"initializationExpression": {
|
|
"assignments": [
|
|
2144
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2144,
|
|
"mutability": "mutable",
|
|
"name": "i",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2192,
|
|
"src": "3011:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2143,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3011:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2146,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2145,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "3023:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "3011:13:1"
|
|
},
|
|
"loopExpression": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2151,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "++",
|
|
"prefix": false,
|
|
"src": "3051:3:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2150,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2144,
|
|
"src": "3051:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2152,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "3051:3:1"
|
|
},
|
|
"nodeType": "ForStatement",
|
|
"src": "3006:427:1"
|
|
}
|
|
]
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2118,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2115,
|
|
"name": "n",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2112,
|
|
"src": "2795:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "<",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2116,
|
|
"name": "anchors",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2085,
|
|
"src": "2799:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2117,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "2799:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "2795:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2194,
|
|
"initializationExpression": {
|
|
"assignments": [
|
|
2112
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2112,
|
|
"mutability": "mutable",
|
|
"name": "n",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2194,
|
|
"src": "2780:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2111,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2780:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2114,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2113,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "2792:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "2780:13:1"
|
|
},
|
|
"loopExpression": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2120,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "++",
|
|
"prefix": false,
|
|
"src": "2815:3:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2119,
|
|
"name": "n",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2112,
|
|
"src": "2815:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2121,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "2815:3:1"
|
|
},
|
|
"nodeType": "ForStatement",
|
|
"src": "2775:669:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2198,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "3477:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
}
|
|
],
|
|
"id": 2197,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "NewExpression",
|
|
"src": "3463:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_objectcreation_pure$_t_uint256_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (uint256) pure returns (address[] memory)"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2195,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3467:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2196,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "3467:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
}
|
|
},
|
|
"id": 2199,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "3463:16:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2069,
|
|
"id": 2200,
|
|
"nodeType": "Return",
|
|
"src": "3456:23:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 2060,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "1997:308:1",
|
|
"text": " @dev generates a conversion path between a given token and the anchor token\n @param _token address of the token\n @param _converterRegistry address of the converter registry\n @return a path from the input token to the anchor token"
|
|
},
|
|
"id": 2202,
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "getPath",
|
|
"nodeType": "FunctionDefinition",
|
|
"overrides": null,
|
|
"parameters": {
|
|
"id": 2065,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2062,
|
|
"mutability": "mutable",
|
|
"name": "_token",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2202,
|
|
"src": "2328:18:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 2061,
|
|
"name": "IERC20Token",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 21127,
|
|
"src": "2328:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 2064,
|
|
"mutability": "mutable",
|
|
"name": "_converterRegistry",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2202,
|
|
"src": "2348:37:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 2063,
|
|
"name": "IConverterRegistry",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 13501,
|
|
"src": "2348:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "2327:59:1"
|
|
},
|
|
"returnParameters": {
|
|
"id": 2069,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2068,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2202,
|
|
"src": "2409:16:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2066,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2409:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2067,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "2409:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "2408:18:1"
|
|
},
|
|
"scope": 2532,
|
|
"src": "2311:1176:1",
|
|
"stateMutability": "view",
|
|
"virtual": false,
|
|
"visibility": "private"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2391,
|
|
"nodeType": "Block",
|
|
"src": "3855:989:1",
|
|
"statements": [
|
|
{
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"id": 2223,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2218,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2215,
|
|
"name": "_sourcePath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2206,
|
|
"src": "3870:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2216,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "3870:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": ">",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2217,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "3891:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"src": "3870:22:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "&&",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2222,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2219,
|
|
"name": "_targetPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2209,
|
|
"src": "3896:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2220,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "3896:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": ">",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2221,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "3917:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"src": "3896:22:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"src": "3870:48:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"falseBody": null,
|
|
"id": 2384,
|
|
"nodeType": "IfStatement",
|
|
"src": "3866:935:1",
|
|
"trueBody": {
|
|
"id": 2383,
|
|
"nodeType": "Block",
|
|
"src": "3920:881:1",
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
2225
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2225,
|
|
"mutability": "mutable",
|
|
"name": "i",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2383,
|
|
"src": "3935:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2224,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3935:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2228,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2226,
|
|
"name": "_sourcePath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2206,
|
|
"src": "3947:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2227,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "3947:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "3935:30:1"
|
|
},
|
|
{
|
|
"assignments": [
|
|
2230
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2230,
|
|
"mutability": "mutable",
|
|
"name": "j",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2383,
|
|
"src": "3980:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2229,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3980:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2233,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2231,
|
|
"name": "_targetPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2209,
|
|
"src": "3992:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2232,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "3992:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "3980:30:1"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2259,
|
|
"nodeType": "Block",
|
|
"src": "4092:60:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2254,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "--",
|
|
"prefix": false,
|
|
"src": "4111:3:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2253,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2225,
|
|
"src": "4111:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2255,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4111:3:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2257,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "--",
|
|
"prefix": false,
|
|
"src": "4133:3:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2256,
|
|
"name": "j",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2230,
|
|
"src": "4133:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2258,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4133:3:1"
|
|
}
|
|
]
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"id": 2252,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"id": 2240,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2236,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2234,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2225,
|
|
"src": "4032:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": ">",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2235,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4036:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"src": "4032:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "&&",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2239,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2237,
|
|
"name": "j",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2230,
|
|
"src": "4041:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": ">",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2238,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4045:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"src": "4041:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"src": "4032:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "&&",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"id": 2251,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2241,
|
|
"name": "_sourcePath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2206,
|
|
"src": "4050:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2245,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2244,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2242,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2225,
|
|
"src": "4062:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "-",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "31",
|
|
"id": 2243,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4066:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_1_by_1",
|
|
"typeString": "int_const 1"
|
|
},
|
|
"value": "1"
|
|
},
|
|
"src": "4062:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4050:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "==",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2246,
|
|
"name": "_targetPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2209,
|
|
"src": "4072:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2250,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2249,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2247,
|
|
"name": "j",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2230,
|
|
"src": "4084:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "-",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "31",
|
|
"id": 2248,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4088:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_1_by_1",
|
|
"typeString": "int_const 1"
|
|
},
|
|
"value": "1"
|
|
},
|
|
"src": "4084:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4072:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "4050:40:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"src": "4032:58:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2260,
|
|
"nodeType": "WhileStatement",
|
|
"src": "4025:127:1"
|
|
},
|
|
{
|
|
"assignments": [
|
|
2265
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2265,
|
|
"mutability": "mutable",
|
|
"name": "path",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2383,
|
|
"src": "4168:21:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2263,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4168:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2264,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "4168:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2275,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2273,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2271,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2269,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2225,
|
|
"src": "4206:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "+",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2270,
|
|
"name": "j",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2230,
|
|
"src": "4210:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "4206:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "+",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "31",
|
|
"id": 2272,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4214:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_1_by_1",
|
|
"typeString": "int_const 1"
|
|
},
|
|
"value": "1"
|
|
},
|
|
"src": "4206:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"id": 2268,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "NewExpression",
|
|
"src": "4192:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_objectcreation_pure$_t_uint256_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (uint256) pure returns (address[] memory)"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2266,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4196:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2267,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "4196:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
}
|
|
},
|
|
"id": 2274,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "4192:24:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "4168:48:1"
|
|
},
|
|
{
|
|
"body": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2292,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2286,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4281:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2288,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2287,
|
|
"name": "m",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2277,
|
|
"src": "4286:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4281:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2289,
|
|
"name": "_sourcePath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2206,
|
|
"src": "4291:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2291,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2290,
|
|
"name": "m",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2277,
|
|
"src": "4303:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4291:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "4281:24:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2293,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4281:24:1"
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2282,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2280,
|
|
"name": "m",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2277,
|
|
"src": "4251:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "<=",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2281,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2225,
|
|
"src": "4256:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "4251:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2294,
|
|
"initializationExpression": {
|
|
"assignments": [
|
|
2277
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2277,
|
|
"mutability": "mutable",
|
|
"name": "m",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2294,
|
|
"src": "4236:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2276,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4236:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2279,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2278,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4248:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "4236:13:1"
|
|
},
|
|
"loopExpression": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2284,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "++",
|
|
"prefix": false,
|
|
"src": "4259:3:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2283,
|
|
"name": "m",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2277,
|
|
"src": "4259:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2285,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4259:3:1"
|
|
},
|
|
"nodeType": "ForStatement",
|
|
"src": "4231:74:1"
|
|
},
|
|
{
|
|
"body": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2316,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2305,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4369:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2310,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2309,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2306,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4374:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2307,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "4374:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "-",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2308,
|
|
"name": "n",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2296,
|
|
"src": "4388:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "4374:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4369:21:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2311,
|
|
"name": "_targetPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2209,
|
|
"src": "4393:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2315,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2314,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2312,
|
|
"name": "n",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2296,
|
|
"src": "4405:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "-",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "31",
|
|
"id": 2313,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4409:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_1_by_1",
|
|
"typeString": "int_const 1"
|
|
},
|
|
"value": "1"
|
|
},
|
|
"src": "4405:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4393:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "4369:42:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2317,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4369:42:1"
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2301,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2299,
|
|
"name": "n",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2296,
|
|
"src": "4340:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": ">",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2300,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4344:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"src": "4340:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2318,
|
|
"initializationExpression": {
|
|
"assignments": [
|
|
2296
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2296,
|
|
"mutability": "mutable",
|
|
"name": "n",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2318,
|
|
"src": "4325:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2295,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4325:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2298,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"id": 2297,
|
|
"name": "j",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2230,
|
|
"src": "4337:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "4325:13:1"
|
|
},
|
|
"loopExpression": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2303,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "--",
|
|
"prefix": false,
|
|
"src": "4347:3:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2302,
|
|
"name": "n",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2296,
|
|
"src": "4347:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2304,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4347:3:1"
|
|
},
|
|
"nodeType": "ForStatement",
|
|
"src": "4320:91:1"
|
|
},
|
|
{
|
|
"assignments": [
|
|
2320
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2320,
|
|
"mutability": "mutable",
|
|
"name": "length",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2383,
|
|
"src": "4428:14:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2319,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4428:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2322,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2321,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4445:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "4428:18:1"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2376,
|
|
"nodeType": "Block",
|
|
"src": "4506:231:1",
|
|
"statements": [
|
|
{
|
|
"body": {
|
|
"id": 2365,
|
|
"nodeType": "Block",
|
|
"src": "4582:97:1",
|
|
"statements": [
|
|
{
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"id": 2359,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2353,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4609:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2355,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2354,
|
|
"name": "p",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2324,
|
|
"src": "4614:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4609:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "==",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2356,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4620:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2358,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2357,
|
|
"name": "q",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2336,
|
|
"src": "4625:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4620:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "4609:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"falseBody": null,
|
|
"id": 2364,
|
|
"nodeType": "IfStatement",
|
|
"src": "4605:54:1",
|
|
"trueBody": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2362,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2360,
|
|
"name": "p",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2324,
|
|
"src": "4654:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2361,
|
|
"name": "q",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2336,
|
|
"src": "4658:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "4654:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2363,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4654:5:1"
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2348,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2341,
|
|
"name": "q",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2336,
|
|
"src": "4549:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "<",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2347,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2342,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4553:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2343,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "4553:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "-",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2346,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2344,
|
|
"name": "p",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2324,
|
|
"src": "4567:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "%",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "32",
|
|
"id": 2345,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4571:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_2_by_1",
|
|
"typeString": "int_const 2"
|
|
},
|
|
"value": "2"
|
|
},
|
|
"src": "4567:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "4553:19:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "4549:23:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2366,
|
|
"initializationExpression": {
|
|
"assignments": [
|
|
2336
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2336,
|
|
"mutability": "mutable",
|
|
"name": "q",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2366,
|
|
"src": "4530:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2335,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4530:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2340,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2339,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2337,
|
|
"name": "p",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2324,
|
|
"src": "4542:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "+",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "32",
|
|
"id": 2338,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4546:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_2_by_1",
|
|
"typeString": "int_const 2"
|
|
},
|
|
"value": "2"
|
|
},
|
|
"src": "4542:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "4530:17:1"
|
|
},
|
|
"loopExpression": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2351,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2349,
|
|
"name": "q",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2336,
|
|
"src": "4574:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "+=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"hexValue": "32",
|
|
"id": 2350,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4579:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_2_by_1",
|
|
"typeString": "int_const 2"
|
|
},
|
|
"value": "2"
|
|
},
|
|
"src": "4574:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2352,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4574:6:1"
|
|
},
|
|
"nodeType": "ForStatement",
|
|
"src": "4525:154:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2374,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2367,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4697:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2370,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2369,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "++",
|
|
"prefix": false,
|
|
"src": "4702:8:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2368,
|
|
"name": "length",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2320,
|
|
"src": "4702:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4697:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2371,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4714:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2373,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2372,
|
|
"name": "p",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2324,
|
|
"src": "4719:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4714:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "4697:24:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2375,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4697:24:1"
|
|
}
|
|
]
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2330,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2327,
|
|
"name": "p",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2324,
|
|
"src": "4481:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "<",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2328,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4485:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2329,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "4485:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "4481:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2377,
|
|
"initializationExpression": {
|
|
"assignments": [
|
|
2324
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2324,
|
|
"mutability": "mutable",
|
|
"name": "p",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2377,
|
|
"src": "4466:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2323,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4466:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2326,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2325,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4478:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "4466:13:1"
|
|
},
|
|
"loopExpression": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2333,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2331,
|
|
"name": "p",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2324,
|
|
"src": "4498:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "+=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"hexValue": "31",
|
|
"id": 2332,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4503:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_1_by_1",
|
|
"typeString": "int_const 1"
|
|
},
|
|
"value": "1"
|
|
},
|
|
"src": "4498:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2334,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4498:6:1"
|
|
},
|
|
"nodeType": "ForStatement",
|
|
"src": "4461:276:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2379,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4776:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2380,
|
|
"name": "length",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2320,
|
|
"src": "4782:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"id": 2378,
|
|
"name": "getPartialArray",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2531,
|
|
"src": "4760:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (address[] memory,uint256) pure returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2381,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "4760:29:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2214,
|
|
"id": 2382,
|
|
"nodeType": "Return",
|
|
"src": "4753:36:1"
|
|
}
|
|
]
|
|
}
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2388,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4834:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
}
|
|
],
|
|
"id": 2387,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "NewExpression",
|
|
"src": "4820:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_objectcreation_pure$_t_uint256_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (uint256) pure returns (address[] memory)"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2385,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4824:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2386,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "4824:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
}
|
|
},
|
|
"id": 2389,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "4820:16:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2214,
|
|
"id": 2390,
|
|
"nodeType": "Return",
|
|
"src": "4813:23:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 2203,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "3495:229:1",
|
|
"text": " @dev merges two paths with a common suffix into one\n @param _sourcePath address of the source path\n @param _targetPath address of the target path\n @return merged path"
|
|
},
|
|
"id": 2392,
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "getShortestPath",
|
|
"nodeType": "FunctionDefinition",
|
|
"overrides": null,
|
|
"parameters": {
|
|
"id": 2210,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2206,
|
|
"mutability": "mutable",
|
|
"name": "_sourcePath",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2392,
|
|
"src": "3755:28:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2204,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3755:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2205,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "3755:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 2209,
|
|
"mutability": "mutable",
|
|
"name": "_targetPath",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2392,
|
|
"src": "3785:28:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2207,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3785:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2208,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "3785:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "3754:60:1"
|
|
},
|
|
"returnParameters": {
|
|
"id": 2214,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2213,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2392,
|
|
"src": "3837:16:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2211,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3837:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2212,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "3837:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "3836:18:1"
|
|
},
|
|
"scope": 2532,
|
|
"src": "3730:1114:1",
|
|
"stateMutability": "pure",
|
|
"virtual": false,
|
|
"visibility": "private"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2420,
|
|
"nodeType": "Block",
|
|
"src": "5084:110:1",
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
2405
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2405,
|
|
"mutability": "mutable",
|
|
"name": "array",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2420,
|
|
"src": "5095:22:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2403,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5095:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2404,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "5095:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2411,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"hexValue": "31",
|
|
"id": 2409,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "5134:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_1_by_1",
|
|
"typeString": "int_const 1"
|
|
},
|
|
"value": "1"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_rational_1_by_1",
|
|
"typeString": "int_const 1"
|
|
}
|
|
],
|
|
"id": 2408,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "NewExpression",
|
|
"src": "5120:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_objectcreation_pure$_t_uint256_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (uint256) pure returns (address[] memory)"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2406,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5124:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2407,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "5124:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
}
|
|
},
|
|
"id": 2410,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "5120:16:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "5095:41:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2416,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2412,
|
|
"name": "array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2405,
|
|
"src": "5147:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2414,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2413,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "5153:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "5147:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2415,
|
|
"name": "_item",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2395,
|
|
"src": "5158:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "5147:16:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2417,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "5147:16:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2418,
|
|
"name": "array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2405,
|
|
"src": "5181:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2400,
|
|
"id": 2419,
|
|
"nodeType": "Return",
|
|
"src": "5174:12:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 2393,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "4852:146:1",
|
|
"text": " @dev creates a new array containing a single item\n @param _item item\n @return initial array"
|
|
},
|
|
"id": 2421,
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "getInitialArray",
|
|
"nodeType": "FunctionDefinition",
|
|
"overrides": null,
|
|
"parameters": {
|
|
"id": 2396,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2395,
|
|
"mutability": "mutable",
|
|
"name": "_item",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2421,
|
|
"src": "5029:13:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 2394,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5029:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "5028:15:1"
|
|
},
|
|
"returnParameters": {
|
|
"id": 2400,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2399,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2421,
|
|
"src": "5066:16:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2397,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5066:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2398,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "5066:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "5065:18:1"
|
|
},
|
|
"scope": 2532,
|
|
"src": "5004:190:1",
|
|
"stateMutability": "pure",
|
|
"virtual": false,
|
|
"visibility": "private"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2485,
|
|
"nodeType": "Block",
|
|
"src": "5560:247:1",
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
2439
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2439,
|
|
"mutability": "mutable",
|
|
"name": "array",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2485,
|
|
"src": "5571:22:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2437,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5571:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2438,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "5571:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2448,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2446,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "32",
|
|
"id": 2443,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "5610:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_2_by_1",
|
|
"typeString": "int_const 2"
|
|
},
|
|
"value": "2"
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "+",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2444,
|
|
"name": "_array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2429,
|
|
"src": "5614:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2445,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "5614:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "5610:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"id": 2442,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "NewExpression",
|
|
"src": "5596:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_objectcreation_pure$_t_uint256_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (uint256) pure returns (address[] memory)"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2440,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5600:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2441,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "5600:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
}
|
|
},
|
|
"id": 2447,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "5596:32:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "5571:57:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2453,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2449,
|
|
"name": "array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2439,
|
|
"src": "5639:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2451,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2450,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "5645:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "5639:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2452,
|
|
"name": "_item0",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2424,
|
|
"src": "5650:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "5639:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2454,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "5639:17:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2459,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2455,
|
|
"name": "array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2439,
|
|
"src": "5667:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2457,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "31",
|
|
"id": 2456,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "5673:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_1_by_1",
|
|
"typeString": "int_const 1"
|
|
},
|
|
"value": "1"
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "5667:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2458,
|
|
"name": "_item1",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2426,
|
|
"src": "5678:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "5667:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2460,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "5667:17:1"
|
|
},
|
|
{
|
|
"body": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2480,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2472,
|
|
"name": "array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2439,
|
|
"src": "5752:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2476,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2475,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "32",
|
|
"id": 2473,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "5758:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_2_by_1",
|
|
"typeString": "int_const 2"
|
|
},
|
|
"value": "2"
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "+",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2474,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2462,
|
|
"src": "5762:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "5758:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "5752:12:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2477,
|
|
"name": "_array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2429,
|
|
"src": "5767:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2479,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2478,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2462,
|
|
"src": "5774:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "5767:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "5752:24:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2481,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "5752:24:1"
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2468,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2465,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2462,
|
|
"src": "5715:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "<",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2466,
|
|
"name": "_array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2429,
|
|
"src": "5719:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2467,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "5719:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "5715:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2482,
|
|
"initializationExpression": {
|
|
"assignments": [
|
|
2462
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2462,
|
|
"mutability": "mutable",
|
|
"name": "i",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2482,
|
|
"src": "5700:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2461,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5700:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2464,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2463,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "5712:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "5700:13:1"
|
|
},
|
|
"loopExpression": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2470,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "++",
|
|
"prefix": false,
|
|
"src": "5734:3:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2469,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2462,
|
|
"src": "5734:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2471,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "5734:3:1"
|
|
},
|
|
"nodeType": "ForStatement",
|
|
"src": "5695:81:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2483,
|
|
"name": "array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2439,
|
|
"src": "5794:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2434,
|
|
"id": 2484,
|
|
"nodeType": "Return",
|
|
"src": "5787:12:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 2422,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "5202:229:1",
|
|
"text": " @dev prepends two items to the beginning of an array\n @param _item0 first item\n @param _item1 second item\n @param _array initial array\n @return extended array"
|
|
},
|
|
"id": 2486,
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "getExtendedArray",
|
|
"nodeType": "FunctionDefinition",
|
|
"overrides": null,
|
|
"parameters": {
|
|
"id": 2430,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2424,
|
|
"mutability": "mutable",
|
|
"name": "_item0",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2486,
|
|
"src": "5463:14:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 2423,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5463:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 2426,
|
|
"mutability": "mutable",
|
|
"name": "_item1",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2486,
|
|
"src": "5479:14:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 2425,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5479:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 2429,
|
|
"mutability": "mutable",
|
|
"name": "_array",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2486,
|
|
"src": "5495:23:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2427,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5495:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2428,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "5495:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "5462:57:1"
|
|
},
|
|
"returnParameters": {
|
|
"id": 2434,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2433,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2486,
|
|
"src": "5542:16:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2431,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5542:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2432,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "5542:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "5541:18:1"
|
|
},
|
|
"scope": 2532,
|
|
"src": "5437:370:1",
|
|
"stateMutability": "pure",
|
|
"virtual": false,
|
|
"visibility": "private"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2530,
|
|
"nodeType": "Block",
|
|
"src": "6112:171:1",
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
2502
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2502,
|
|
"mutability": "mutable",
|
|
"name": "array",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2530,
|
|
"src": "6123:22:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2500,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6123:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2501,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "6123:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2508,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2506,
|
|
"name": "_length",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2492,
|
|
"src": "6162:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"id": 2505,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "NewExpression",
|
|
"src": "6148:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_objectcreation_pure$_t_uint256_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (uint256) pure returns (address[] memory)"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2503,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6152:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2504,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "6152:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
}
|
|
},
|
|
"id": 2507,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "6148:22:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "6123:47:1"
|
|
},
|
|
{
|
|
"body": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2525,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2519,
|
|
"name": "array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2502,
|
|
"src": "6232:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2521,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2520,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2510,
|
|
"src": "6238:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "6232:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2522,
|
|
"name": "_array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2490,
|
|
"src": "6243:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2524,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2523,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2510,
|
|
"src": "6250:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "6243:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "6232:20:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2526,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "6232:20:1"
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2515,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2513,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2510,
|
|
"src": "6201:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "<",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2514,
|
|
"name": "_length",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2492,
|
|
"src": "6205:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "6201:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2527,
|
|
"initializationExpression": {
|
|
"assignments": [
|
|
2510
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2510,
|
|
"mutability": "mutable",
|
|
"name": "i",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2527,
|
|
"src": "6186:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2509,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6186:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2512,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2511,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "6198:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "6186:13:1"
|
|
},
|
|
"loopExpression": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2517,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "++",
|
|
"prefix": false,
|
|
"src": "6214:3:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2516,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2510,
|
|
"src": "6214:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2518,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "6214:3:1"
|
|
},
|
|
"nodeType": "ForStatement",
|
|
"src": "6181:71:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2528,
|
|
"name": "array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2502,
|
|
"src": "6270:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2497,
|
|
"id": 2529,
|
|
"nodeType": "Return",
|
|
"src": "6263:12:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 2487,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "5815:184:1",
|
|
"text": " @dev extracts the prefix of a given array\n @param _array given array\n @param _length prefix length\n @return partial array"
|
|
},
|
|
"id": 2531,
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "getPartialArray",
|
|
"nodeType": "FunctionDefinition",
|
|
"overrides": null,
|
|
"parameters": {
|
|
"id": 2493,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2490,
|
|
"mutability": "mutable",
|
|
"name": "_array",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2531,
|
|
"src": "6030:23:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2488,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6030:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2489,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "6030:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 2492,
|
|
"mutability": "mutable",
|
|
"name": "_length",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2531,
|
|
"src": "6055:15:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2491,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6055:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "6029:42:1"
|
|
},
|
|
"returnParameters": {
|
|
"id": 2497,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2496,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2531,
|
|
"src": "6094:16:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2494,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6094:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2495,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "6094:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "6093:18:1"
|
|
},
|
|
"scope": 2532,
|
|
"src": "6005:278:1",
|
|
"stateMutability": "pure",
|
|
"virtual": false,
|
|
"visibility": "private"
|
|
}
|
|
],
|
|
"scope": 2533,
|
|
"src": "614:5672:1"
|
|
}
|
|
],
|
|
"src": "52:6236:1"
|
|
},
|
|
"legacyAST": {
|
|
"absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/ConversionPathFinder.sol",
|
|
"exportedSymbols": {
|
|
"ConversionPathFinder": [
|
|
2532
|
|
]
|
|
},
|
|
"id": 2533,
|
|
"license": "SEE LICENSE IN LICENSE",
|
|
"nodeType": "SourceUnit",
|
|
"nodes": [
|
|
{
|
|
"id": 1978,
|
|
"literals": [
|
|
"solidity",
|
|
"0.6",
|
|
".12"
|
|
],
|
|
"nodeType": "PragmaDirective",
|
|
"src": "52:23:1"
|
|
},
|
|
{
|
|
"absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/IConversionPathFinder.sol",
|
|
"file": "./IConversionPathFinder.sol",
|
|
"id": 1979,
|
|
"nodeType": "ImportDirective",
|
|
"scope": 2533,
|
|
"sourceUnit": 2547,
|
|
"src": "77:37:1",
|
|
"symbolAliases": [],
|
|
"unitAlias": ""
|
|
},
|
|
{
|
|
"absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/utility/ContractRegistryClient.sol",
|
|
"file": "./utility/ContractRegistryClient.sol",
|
|
"id": 1980,
|
|
"nodeType": "ImportDirective",
|
|
"scope": 2533,
|
|
"sourceUnit": 21720,
|
|
"src": "116:46:1",
|
|
"symbolAliases": [],
|
|
"unitAlias": ""
|
|
},
|
|
{
|
|
"absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IConverter.sol",
|
|
"file": "./converter/interfaces/IConverter.sol",
|
|
"id": 1981,
|
|
"nodeType": "ImportDirective",
|
|
"scope": 2533,
|
|
"sourceUnit": 13341,
|
|
"src": "164:47:1",
|
|
"symbolAliases": [],
|
|
"unitAlias": ""
|
|
},
|
|
{
|
|
"absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IConverterAnchor.sol",
|
|
"file": "./converter/interfaces/IConverterAnchor.sol",
|
|
"id": 1982,
|
|
"nodeType": "ImportDirective",
|
|
"scope": 2533,
|
|
"sourceUnit": 13350,
|
|
"src": "213:53:1",
|
|
"symbolAliases": [],
|
|
"unitAlias": ""
|
|
},
|
|
{
|
|
"absolutePath": "/home/lash/src/ext/cic/grassrootseconomics/bancor-contracts/solidity/contracts/converter/interfaces/IConverterRegistry.sol",
|
|
"file": "./converter/interfaces/IConverterRegistry.sol",
|
|
"id": 1983,
|
|
"nodeType": "ImportDirective",
|
|
"scope": 2533,
|
|
"sourceUnit": 13502,
|
|
"src": "268:55:1",
|
|
"symbolAliases": [],
|
|
"unitAlias": ""
|
|
},
|
|
{
|
|
"abstract": false,
|
|
"baseContracts": [
|
|
{
|
|
"arguments": null,
|
|
"baseName": {
|
|
"contractScope": null,
|
|
"id": 1985,
|
|
"name": "IConversionPathFinder",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 2546,
|
|
"src": "647:21:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConversionPathFinder_$2546",
|
|
"typeString": "contract IConversionPathFinder"
|
|
}
|
|
},
|
|
"id": 1986,
|
|
"nodeType": "InheritanceSpecifier",
|
|
"src": "647:21:1"
|
|
},
|
|
{
|
|
"arguments": null,
|
|
"baseName": {
|
|
"contractScope": null,
|
|
"id": 1987,
|
|
"name": "ContractRegistryClient",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 21719,
|
|
"src": "670:22:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_ContractRegistryClient_$21719",
|
|
"typeString": "contract ContractRegistryClient"
|
|
}
|
|
},
|
|
"id": 1988,
|
|
"nodeType": "InheritanceSpecifier",
|
|
"src": "670:22:1"
|
|
}
|
|
],
|
|
"contractDependencies": [
|
|
2546,
|
|
21719,
|
|
21818,
|
|
22661,
|
|
22847
|
|
],
|
|
"contractKind": "contract",
|
|
"documentation": {
|
|
"id": 1984,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "327:285:1",
|
|
"text": " @dev The ConversionPathFinder contract allows generating a conversion path between any token pair in the Bancor Network.\n The path can then be used in various functions in the BancorNetwork contract.\n See the BancorNetwork contract for conversion path format."
|
|
},
|
|
"fullyImplemented": true,
|
|
"id": 2532,
|
|
"linearizedBaseContracts": [
|
|
2532,
|
|
21719,
|
|
22661,
|
|
21818,
|
|
22847,
|
|
2546
|
|
],
|
|
"name": "ConversionPathFinder",
|
|
"nodeType": "ContractDefinition",
|
|
"nodes": [
|
|
{
|
|
"constant": false,
|
|
"functionSelector": "e1c4c966",
|
|
"id": 1990,
|
|
"mutability": "mutable",
|
|
"name": "anchorToken",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2532,
|
|
"src": "700:30:1",
|
|
"stateVariable": true,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 1989,
|
|
"name": "IERC20Token",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 21127,
|
|
"src": "700:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 1999,
|
|
"nodeType": "Block",
|
|
"src": "975:8:1",
|
|
"statements": []
|
|
},
|
|
"documentation": {
|
|
"id": 1991,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "739:148:1",
|
|
"text": " @dev initializes a new ConversionPathFinder instance\n @param _registry address of a contract registry contract"
|
|
},
|
|
"id": 2000,
|
|
"implemented": true,
|
|
"kind": "constructor",
|
|
"modifiers": [
|
|
{
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 1996,
|
|
"name": "_registry",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1993,
|
|
"src": "957:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IContractRegistry_$22831",
|
|
"typeString": "contract IContractRegistry"
|
|
}
|
|
}
|
|
],
|
|
"id": 1997,
|
|
"modifierName": {
|
|
"argumentTypes": null,
|
|
"id": 1995,
|
|
"name": "ContractRegistryClient",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 21719,
|
|
"src": "934:22:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_contract$_ContractRegistryClient_$21719_$",
|
|
"typeString": "type(contract ContractRegistryClient)"
|
|
}
|
|
},
|
|
"nodeType": "ModifierInvocation",
|
|
"src": "934:33:1"
|
|
}
|
|
],
|
|
"name": "",
|
|
"nodeType": "FunctionDefinition",
|
|
"overrides": null,
|
|
"parameters": {
|
|
"id": 1994,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 1993,
|
|
"mutability": "mutable",
|
|
"name": "_registry",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2000,
|
|
"src": "905:27:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IContractRegistry_$22831",
|
|
"typeString": "contract IContractRegistry"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 1992,
|
|
"name": "IContractRegistry",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 22831,
|
|
"src": "905:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IContractRegistry_$22831",
|
|
"typeString": "contract IContractRegistry"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "904:29:1"
|
|
},
|
|
"returnParameters": {
|
|
"id": 1998,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [],
|
|
"src": "975:0:1"
|
|
},
|
|
"scope": 2532,
|
|
"src": "893:90:1",
|
|
"stateMutability": "nonpayable",
|
|
"virtual": false,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2012,
|
|
"nodeType": "Block",
|
|
"src": "1180:45:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2010,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2008,
|
|
"name": "anchorToken",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1990,
|
|
"src": "1191:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2009,
|
|
"name": "_anchorToken",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2003,
|
|
"src": "1205:12:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"src": "1191:26:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"id": 2011,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "1191:26:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 2001,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "991:116:1",
|
|
"text": " @dev updates the anchor token\n @param _anchorToken address of the anchor token"
|
|
},
|
|
"functionSelector": "2f167f05",
|
|
"id": 2013,
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [
|
|
{
|
|
"arguments": null,
|
|
"id": 2006,
|
|
"modifierName": {
|
|
"argumentTypes": null,
|
|
"id": 2005,
|
|
"name": "ownerOnly",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 21754,
|
|
"src": "1170:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_modifier$__$",
|
|
"typeString": "modifier ()"
|
|
}
|
|
},
|
|
"nodeType": "ModifierInvocation",
|
|
"src": "1170:9:1"
|
|
}
|
|
],
|
|
"name": "setAnchorToken",
|
|
"nodeType": "FunctionDefinition",
|
|
"overrides": null,
|
|
"parameters": {
|
|
"id": 2004,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2003,
|
|
"mutability": "mutable",
|
|
"name": "_anchorToken",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2013,
|
|
"src": "1137:24:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 2002,
|
|
"name": "IERC20Token",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 21127,
|
|
"src": "1137:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "1136:26:1"
|
|
},
|
|
"returnParameters": {
|
|
"id": 2007,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [],
|
|
"src": "1180:0:1"
|
|
},
|
|
"scope": 2532,
|
|
"src": "1113:112:1",
|
|
"stateMutability": "nonpayable",
|
|
"virtual": false,
|
|
"visibility": "public"
|
|
},
|
|
{
|
|
"baseFunctions": [
|
|
2545
|
|
],
|
|
"body": {
|
|
"id": 2058,
|
|
"nodeType": "Block",
|
|
"src": "1663:326:1",
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
2026
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2026,
|
|
"mutability": "mutable",
|
|
"name": "converterRegistry",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2058,
|
|
"src": "1674:36:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 2025,
|
|
"name": "IConverterRegistry",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 13501,
|
|
"src": "1674:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2032,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2029,
|
|
"name": "CONVERTER_REGISTRY",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 21545,
|
|
"src": "1742:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bytes32",
|
|
"typeString": "bytes32"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_bytes32",
|
|
"typeString": "bytes32"
|
|
}
|
|
],
|
|
"id": 2028,
|
|
"name": "addressOf",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 21718,
|
|
"src": "1732:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$",
|
|
"typeString": "function (bytes32) view returns (address)"
|
|
}
|
|
},
|
|
"id": 2030,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1732:29:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
],
|
|
"id": 2027,
|
|
"name": "IConverterRegistry",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 13501,
|
|
"src": "1713:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_contract$_IConverterRegistry_$13501_$",
|
|
"typeString": "type(contract IConverterRegistry)"
|
|
}
|
|
},
|
|
"id": 2031,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1713:49:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "1674:88:1"
|
|
},
|
|
{
|
|
"assignments": [
|
|
2037
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2037,
|
|
"mutability": "mutable",
|
|
"name": "sourcePath",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2058,
|
|
"src": "1773:27:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2035,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1773:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2036,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "1773:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2042,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2039,
|
|
"name": "_sourceToken",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2016,
|
|
"src": "1811:12:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2040,
|
|
"name": "converterRegistry",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2026,
|
|
"src": "1825:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
],
|
|
"id": 2038,
|
|
"name": "getPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2202,
|
|
"src": "1803:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_view$_t_contract$_IERC20Token_$21127_$_t_contract$_IConverterRegistry_$13501_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (contract IERC20Token,contract IConverterRegistry) view returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2041,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1803:40:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "1773:70:1"
|
|
},
|
|
{
|
|
"assignments": [
|
|
2047
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2047,
|
|
"mutability": "mutable",
|
|
"name": "targetPath",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2058,
|
|
"src": "1854:27:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2045,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1854:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2046,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "1854:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2052,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2049,
|
|
"name": "_targetToken",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2018,
|
|
"src": "1892:12:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2050,
|
|
"name": "converterRegistry",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2026,
|
|
"src": "1906:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
],
|
|
"id": 2048,
|
|
"name": "getPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2202,
|
|
"src": "1884:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_view$_t_contract$_IERC20Token_$21127_$_t_contract$_IConverterRegistry_$13501_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (contract IERC20Token,contract IConverterRegistry) view returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2051,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1884:40:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "1854:70:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2054,
|
|
"name": "sourcePath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2037,
|
|
"src": "1958:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2055,
|
|
"name": "targetPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2047,
|
|
"src": "1970:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
],
|
|
"id": 2053,
|
|
"name": "getShortestPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2392,
|
|
"src": "1942:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_array$_t_address_$dyn_memory_ptr_$_t_array$_t_address_$dyn_memory_ptr_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (address[] memory,address[] memory) pure returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2056,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "1942:39:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2024,
|
|
"id": 2057,
|
|
"nodeType": "Return",
|
|
"src": "1935:46:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 2014,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "1233:304:1",
|
|
"text": " @dev generates a conversion path between a given pair of tokens in the Bancor Network\n @param _sourceToken address of the source token\n @param _targetToken address of the target token\n @return a path from the source token to the target token"
|
|
},
|
|
"functionSelector": "a1c421cd",
|
|
"id": 2059,
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "findPath",
|
|
"nodeType": "FunctionDefinition",
|
|
"overrides": {
|
|
"id": 2020,
|
|
"nodeType": "OverrideSpecifier",
|
|
"overrides": [],
|
|
"src": "1627:8:1"
|
|
},
|
|
"parameters": {
|
|
"id": 2019,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2016,
|
|
"mutability": "mutable",
|
|
"name": "_sourceToken",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2059,
|
|
"src": "1561:24:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 2015,
|
|
"name": "IERC20Token",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 21127,
|
|
"src": "1561:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 2018,
|
|
"mutability": "mutable",
|
|
"name": "_targetToken",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2059,
|
|
"src": "1587:24:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 2017,
|
|
"name": "IERC20Token",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 21127,
|
|
"src": "1587:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "1560:52:1"
|
|
},
|
|
"returnParameters": {
|
|
"id": 2024,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2023,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2059,
|
|
"src": "1645:16:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2021,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "1645:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2022,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "1645:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "1644:18:1"
|
|
},
|
|
"scope": 2532,
|
|
"src": "1543:446:1",
|
|
"stateMutability": "view",
|
|
"virtual": false,
|
|
"visibility": "external"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2201,
|
|
"nodeType": "Block",
|
|
"src": "2427:1060:1",
|
|
"statements": [
|
|
{
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
"id": 2072,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2070,
|
|
"name": "_token",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2062,
|
|
"src": "2442:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "==",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2071,
|
|
"name": "anchorToken",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 1990,
|
|
"src": "2452:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"src": "2442:21:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"falseBody": null,
|
|
"id": 2080,
|
|
"nodeType": "IfStatement",
|
|
"src": "2438:79:1",
|
|
"trueBody": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2076,
|
|
"name": "_token",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2062,
|
|
"src": "2509:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
],
|
|
"id": 2075,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "ElementaryTypeNameExpression",
|
|
"src": "2501:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_address_$",
|
|
"typeString": "type(address)"
|
|
},
|
|
"typeName": {
|
|
"id": 2074,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2501:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": null,
|
|
"typeString": null
|
|
}
|
|
}
|
|
},
|
|
"id": 2077,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2501:15:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
],
|
|
"id": 2073,
|
|
"name": "getInitialArray",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2421,
|
|
"src": "2485:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_address_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (address) pure returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2078,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2485:32:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2069,
|
|
"id": 2079,
|
|
"nodeType": "Return",
|
|
"src": "2478:39:1"
|
|
}
|
|
},
|
|
{
|
|
"assignments": [
|
|
2085
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2085,
|
|
"mutability": "mutable",
|
|
"name": "anchors",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2201,
|
|
"src": "2530:24:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2083,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2530:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2084,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "2530:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2086,
|
|
"initialValue": null,
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "2530:24:1"
|
|
},
|
|
{
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2091,
|
|
"name": "_token",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2062,
|
|
"src": "2605:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
],
|
|
"id": 2090,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "ElementaryTypeNameExpression",
|
|
"src": "2597:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_address_$",
|
|
"typeString": "type(address)"
|
|
},
|
|
"typeName": {
|
|
"id": 2089,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2597:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": null,
|
|
"typeString": null
|
|
}
|
|
}
|
|
},
|
|
"id": 2092,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2597:15:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2087,
|
|
"name": "_converterRegistry",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2064,
|
|
"src": "2569:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
},
|
|
"id": 2088,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "isAnchor",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 13417,
|
|
"src": "2569:27:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$",
|
|
"typeString": "function (address) view external returns (bool)"
|
|
}
|
|
},
|
|
"id": 2093,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2569:44:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"falseBody": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2108,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2103,
|
|
"name": "anchors",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2085,
|
|
"src": "2699:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2106,
|
|
"name": "_token",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2062,
|
|
"src": "2755:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2104,
|
|
"name": "_converterRegistry",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2064,
|
|
"src": "2709:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
},
|
|
"id": 2105,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "getConvertibleTokenAnchors",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 13482,
|
|
"src": "2709:45:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_external_view$_t_contract$_IERC20Token_$21127_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (contract IERC20Token) view external returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2107,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2709:53:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"src": "2699:63:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2109,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "2699:63:1"
|
|
},
|
|
"id": 2110,
|
|
"nodeType": "IfStatement",
|
|
"src": "2565:197:1",
|
|
"trueBody": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2101,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2094,
|
|
"name": "anchors",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2085,
|
|
"src": "2628:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2098,
|
|
"name": "_token",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2062,
|
|
"src": "2662:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
],
|
|
"id": 2097,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "ElementaryTypeNameExpression",
|
|
"src": "2654:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_address_$",
|
|
"typeString": "type(address)"
|
|
},
|
|
"typeName": {
|
|
"id": 2096,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2654:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": null,
|
|
"typeString": null
|
|
}
|
|
}
|
|
},
|
|
"id": 2099,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2654:15:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
],
|
|
"id": 2095,
|
|
"name": "getInitialArray",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2421,
|
|
"src": "2638:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_address_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (address) pure returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2100,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2638:32:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"src": "2628:42:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2102,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "2628:42:1"
|
|
}
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2193,
|
|
"nodeType": "Block",
|
|
"src": "2820:624:1",
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
2123
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2123,
|
|
"mutability": "mutable",
|
|
"name": "converter",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2193,
|
|
"src": "2835:20:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverter_$13340",
|
|
"typeString": "contract IConverter"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 2122,
|
|
"name": "IConverter",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 13340,
|
|
"src": "2835:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverter_$13340",
|
|
"typeString": "contract IConverter"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2136,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"arguments": [],
|
|
"expression": {
|
|
"argumentTypes": [],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2128,
|
|
"name": "anchors",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2085,
|
|
"src": "2894:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2130,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2129,
|
|
"name": "n",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2112,
|
|
"src": "2902:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "2894:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
],
|
|
"id": 2127,
|
|
"name": "IConverterAnchor",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 13349,
|
|
"src": "2877:16:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_contract$_IConverterAnchor_$13349_$",
|
|
"typeString": "type(contract IConverterAnchor)"
|
|
}
|
|
},
|
|
"id": 2131,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2877:28:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterAnchor_$13349",
|
|
"typeString": "contract IConverterAnchor"
|
|
}
|
|
},
|
|
"id": 2132,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "owner",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 22838,
|
|
"src": "2877:34:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_external_view$__$returns$_t_address_$",
|
|
"typeString": "function () view external returns (address)"
|
|
}
|
|
},
|
|
"id": 2133,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2877:36:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
],
|
|
"id": 2126,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "ElementaryTypeNameExpression",
|
|
"src": "2869:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_address_payable_$",
|
|
"typeString": "type(address payable)"
|
|
},
|
|
"typeName": {
|
|
"id": 2125,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2869:8:1",
|
|
"stateMutability": "payable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": null,
|
|
"typeString": null
|
|
}
|
|
}
|
|
},
|
|
"id": 2134,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2869:45:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address_payable",
|
|
"typeString": "address payable"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address_payable",
|
|
"typeString": "address payable"
|
|
}
|
|
],
|
|
"id": 2124,
|
|
"name": "IConverter",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 13340,
|
|
"src": "2858:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_contract$_IConverter_$13340_$",
|
|
"typeString": "type(contract IConverter)"
|
|
}
|
|
},
|
|
"id": 2135,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2858:57:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverter_$13340",
|
|
"typeString": "contract IConverter"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "2835:80:1"
|
|
},
|
|
{
|
|
"assignments": [
|
|
2138
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2138,
|
|
"mutability": "mutable",
|
|
"name": "connectorTokenCount",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2193,
|
|
"src": "2930:27:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2137,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2930:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2142,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [],
|
|
"expression": {
|
|
"argumentTypes": [],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2139,
|
|
"name": "converter",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2123,
|
|
"src": "2960:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverter_$13340",
|
|
"typeString": "contract IConverter"
|
|
}
|
|
},
|
|
"id": 2140,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "connectorTokenCount",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 13339,
|
|
"src": "2960:29:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_external_view$__$returns$_t_uint16_$",
|
|
"typeString": "function () view external returns (uint16)"
|
|
}
|
|
},
|
|
"id": 2141,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "2960:31:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint16",
|
|
"typeString": "uint16"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "2930:61:1"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2191,
|
|
"nodeType": "Block",
|
|
"src": "3056:377:1",
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
2154
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2154,
|
|
"mutability": "mutable",
|
|
"name": "connectorToken",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2191,
|
|
"src": "3075:26:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 2153,
|
|
"name": "IERC20Token",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 21127,
|
|
"src": "3075:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2159,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2157,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2144,
|
|
"src": "3130:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2155,
|
|
"name": "converter",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2123,
|
|
"src": "3104:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverter_$13340",
|
|
"typeString": "contract IConverter"
|
|
}
|
|
},
|
|
"id": 2156,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "connectorTokens",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": 13334,
|
|
"src": "3104:25:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_contract$_IERC20Token_$21127_$",
|
|
"typeString": "function (uint256) view external returns (contract IERC20Token)"
|
|
}
|
|
},
|
|
"id": 2158,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "3104:28:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "3075:57:1"
|
|
},
|
|
{
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
"id": 2162,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2160,
|
|
"name": "connectorToken",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2154,
|
|
"src": "3155:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "!=",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2161,
|
|
"name": "_token",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2062,
|
|
"src": "3173:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"src": "3155:24:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"falseBody": null,
|
|
"id": 2190,
|
|
"nodeType": "IfStatement",
|
|
"src": "3151:267:1",
|
|
"trueBody": {
|
|
"id": 2189,
|
|
"nodeType": "Block",
|
|
"src": "3181:237:1",
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
2167
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2167,
|
|
"mutability": "mutable",
|
|
"name": "path",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2189,
|
|
"src": "3204:21:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2165,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3204:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2166,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "3204:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2172,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2169,
|
|
"name": "connectorToken",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2154,
|
|
"src": "3236:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2170,
|
|
"name": "_converterRegistry",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2064,
|
|
"src": "3252:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
],
|
|
"id": 2168,
|
|
"name": "getPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2202,
|
|
"src": "3228:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_view$_t_contract$_IERC20Token_$21127_$_t_contract$_IConverterRegistry_$13501_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (contract IERC20Token,contract IConverterRegistry) view returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2171,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "3228:43:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "3204:67:1"
|
|
},
|
|
{
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2176,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2173,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2167,
|
|
"src": "3298:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2174,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "3298:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": ">",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2175,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "3312:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"src": "3298:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"falseBody": null,
|
|
"id": 2188,
|
|
"nodeType": "IfStatement",
|
|
"src": "3294:104:1",
|
|
"trueBody": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2180,
|
|
"name": "_token",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2062,
|
|
"src": "3372:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
],
|
|
"id": 2179,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "ElementaryTypeNameExpression",
|
|
"src": "3364:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_type$_t_address_$",
|
|
"typeString": "type(address)"
|
|
},
|
|
"typeName": {
|
|
"id": 2178,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3364:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": null,
|
|
"typeString": null
|
|
}
|
|
}
|
|
},
|
|
"id": 2181,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "typeConversion",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "3364:15:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2182,
|
|
"name": "anchors",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2085,
|
|
"src": "3381:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2184,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2183,
|
|
"name": "n",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2112,
|
|
"src": "3389:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "3381:10:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2185,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2167,
|
|
"src": "3393:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
],
|
|
"id": 2177,
|
|
"name": "getExtendedArray",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2486,
|
|
"src": "3347:16:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_address_$_t_address_$_t_array$_t_address_$dyn_memory_ptr_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (address,address,address[] memory) pure returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2186,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "3347:51:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2069,
|
|
"id": 2187,
|
|
"nodeType": "Return",
|
|
"src": "3340:58:1"
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2149,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2147,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2144,
|
|
"src": "3026:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "<",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2148,
|
|
"name": "connectorTokenCount",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2138,
|
|
"src": "3030:19:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "3026:23:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2192,
|
|
"initializationExpression": {
|
|
"assignments": [
|
|
2144
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2144,
|
|
"mutability": "mutable",
|
|
"name": "i",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2192,
|
|
"src": "3011:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2143,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3011:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2146,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2145,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "3023:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "3011:13:1"
|
|
},
|
|
"loopExpression": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2151,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "++",
|
|
"prefix": false,
|
|
"src": "3051:3:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2150,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2144,
|
|
"src": "3051:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2152,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "3051:3:1"
|
|
},
|
|
"nodeType": "ForStatement",
|
|
"src": "3006:427:1"
|
|
}
|
|
]
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2118,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2115,
|
|
"name": "n",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2112,
|
|
"src": "2795:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "<",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2116,
|
|
"name": "anchors",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2085,
|
|
"src": "2799:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2117,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "2799:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "2795:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2194,
|
|
"initializationExpression": {
|
|
"assignments": [
|
|
2112
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2112,
|
|
"mutability": "mutable",
|
|
"name": "n",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2194,
|
|
"src": "2780:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2111,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2780:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2114,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2113,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "2792:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "2780:13:1"
|
|
},
|
|
"loopExpression": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2120,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "++",
|
|
"prefix": false,
|
|
"src": "2815:3:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2119,
|
|
"name": "n",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2112,
|
|
"src": "2815:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2121,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "2815:3:1"
|
|
},
|
|
"nodeType": "ForStatement",
|
|
"src": "2775:669:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2198,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "3477:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
}
|
|
],
|
|
"id": 2197,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "NewExpression",
|
|
"src": "3463:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_objectcreation_pure$_t_uint256_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (uint256) pure returns (address[] memory)"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2195,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3467:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2196,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "3467:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
}
|
|
},
|
|
"id": 2199,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "3463:16:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2069,
|
|
"id": 2200,
|
|
"nodeType": "Return",
|
|
"src": "3456:23:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 2060,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "1997:308:1",
|
|
"text": " @dev generates a conversion path between a given token and the anchor token\n @param _token address of the token\n @param _converterRegistry address of the converter registry\n @return a path from the input token to the anchor token"
|
|
},
|
|
"id": 2202,
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "getPath",
|
|
"nodeType": "FunctionDefinition",
|
|
"overrides": null,
|
|
"parameters": {
|
|
"id": 2065,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2062,
|
|
"mutability": "mutable",
|
|
"name": "_token",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2202,
|
|
"src": "2328:18:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 2061,
|
|
"name": "IERC20Token",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 21127,
|
|
"src": "2328:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IERC20Token_$21127",
|
|
"typeString": "contract IERC20Token"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 2064,
|
|
"mutability": "mutable",
|
|
"name": "_converterRegistry",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2202,
|
|
"src": "2348:37:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
},
|
|
"typeName": {
|
|
"contractScope": null,
|
|
"id": 2063,
|
|
"name": "IConverterRegistry",
|
|
"nodeType": "UserDefinedTypeName",
|
|
"referencedDeclaration": 13501,
|
|
"src": "2348:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_contract$_IConverterRegistry_$13501",
|
|
"typeString": "contract IConverterRegistry"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "2327:59:1"
|
|
},
|
|
"returnParameters": {
|
|
"id": 2069,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2068,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2202,
|
|
"src": "2409:16:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2066,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "2409:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2067,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "2409:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "2408:18:1"
|
|
},
|
|
"scope": 2532,
|
|
"src": "2311:1176:1",
|
|
"stateMutability": "view",
|
|
"virtual": false,
|
|
"visibility": "private"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2391,
|
|
"nodeType": "Block",
|
|
"src": "3855:989:1",
|
|
"statements": [
|
|
{
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"id": 2223,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2218,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2215,
|
|
"name": "_sourcePath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2206,
|
|
"src": "3870:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2216,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "3870:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": ">",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2217,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "3891:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"src": "3870:22:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "&&",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2222,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2219,
|
|
"name": "_targetPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2209,
|
|
"src": "3896:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2220,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "3896:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": ">",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2221,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "3917:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"src": "3896:22:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"src": "3870:48:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"falseBody": null,
|
|
"id": 2384,
|
|
"nodeType": "IfStatement",
|
|
"src": "3866:935:1",
|
|
"trueBody": {
|
|
"id": 2383,
|
|
"nodeType": "Block",
|
|
"src": "3920:881:1",
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
2225
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2225,
|
|
"mutability": "mutable",
|
|
"name": "i",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2383,
|
|
"src": "3935:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2224,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3935:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2228,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2226,
|
|
"name": "_sourcePath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2206,
|
|
"src": "3947:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2227,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "3947:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "3935:30:1"
|
|
},
|
|
{
|
|
"assignments": [
|
|
2230
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2230,
|
|
"mutability": "mutable",
|
|
"name": "j",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2383,
|
|
"src": "3980:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2229,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3980:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2233,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2231,
|
|
"name": "_targetPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2209,
|
|
"src": "3992:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2232,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "3992:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "3980:30:1"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2259,
|
|
"nodeType": "Block",
|
|
"src": "4092:60:1",
|
|
"statements": [
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2254,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "--",
|
|
"prefix": false,
|
|
"src": "4111:3:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2253,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2225,
|
|
"src": "4111:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2255,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4111:3:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2257,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "--",
|
|
"prefix": false,
|
|
"src": "4133:3:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2256,
|
|
"name": "j",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2230,
|
|
"src": "4133:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2258,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4133:3:1"
|
|
}
|
|
]
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"id": 2252,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
},
|
|
"id": 2240,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2236,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2234,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2225,
|
|
"src": "4032:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": ">",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2235,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4036:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"src": "4032:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "&&",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2239,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2237,
|
|
"name": "j",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2230,
|
|
"src": "4041:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": ">",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2238,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4045:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"src": "4041:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"src": "4032:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "&&",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"id": 2251,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2241,
|
|
"name": "_sourcePath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2206,
|
|
"src": "4050:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2245,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2244,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2242,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2225,
|
|
"src": "4062:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "-",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "31",
|
|
"id": 2243,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4066:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_1_by_1",
|
|
"typeString": "int_const 1"
|
|
},
|
|
"value": "1"
|
|
},
|
|
"src": "4062:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4050:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "==",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2246,
|
|
"name": "_targetPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2209,
|
|
"src": "4072:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2250,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2249,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2247,
|
|
"name": "j",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2230,
|
|
"src": "4084:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "-",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "31",
|
|
"id": 2248,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4088:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_1_by_1",
|
|
"typeString": "int_const 1"
|
|
},
|
|
"value": "1"
|
|
},
|
|
"src": "4084:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4072:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "4050:40:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"src": "4032:58:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2260,
|
|
"nodeType": "WhileStatement",
|
|
"src": "4025:127:1"
|
|
},
|
|
{
|
|
"assignments": [
|
|
2265
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2265,
|
|
"mutability": "mutable",
|
|
"name": "path",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2383,
|
|
"src": "4168:21:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2263,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4168:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2264,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "4168:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2275,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2273,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2271,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2269,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2225,
|
|
"src": "4206:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "+",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2270,
|
|
"name": "j",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2230,
|
|
"src": "4210:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "4206:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "+",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "31",
|
|
"id": 2272,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4214:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_1_by_1",
|
|
"typeString": "int_const 1"
|
|
},
|
|
"value": "1"
|
|
},
|
|
"src": "4206:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"id": 2268,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "NewExpression",
|
|
"src": "4192:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_objectcreation_pure$_t_uint256_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (uint256) pure returns (address[] memory)"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2266,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4196:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2267,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "4196:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
}
|
|
},
|
|
"id": 2274,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "4192:24:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "4168:48:1"
|
|
},
|
|
{
|
|
"body": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2292,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2286,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4281:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2288,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2287,
|
|
"name": "m",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2277,
|
|
"src": "4286:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4281:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2289,
|
|
"name": "_sourcePath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2206,
|
|
"src": "4291:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2291,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2290,
|
|
"name": "m",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2277,
|
|
"src": "4303:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4291:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "4281:24:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2293,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4281:24:1"
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2282,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2280,
|
|
"name": "m",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2277,
|
|
"src": "4251:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "<=",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2281,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2225,
|
|
"src": "4256:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "4251:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2294,
|
|
"initializationExpression": {
|
|
"assignments": [
|
|
2277
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2277,
|
|
"mutability": "mutable",
|
|
"name": "m",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2294,
|
|
"src": "4236:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2276,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4236:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2279,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2278,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4248:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "4236:13:1"
|
|
},
|
|
"loopExpression": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2284,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "++",
|
|
"prefix": false,
|
|
"src": "4259:3:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2283,
|
|
"name": "m",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2277,
|
|
"src": "4259:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2285,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4259:3:1"
|
|
},
|
|
"nodeType": "ForStatement",
|
|
"src": "4231:74:1"
|
|
},
|
|
{
|
|
"body": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2316,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2305,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4369:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2310,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2309,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2306,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4374:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2307,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "4374:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "-",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2308,
|
|
"name": "n",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2296,
|
|
"src": "4388:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "4374:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4369:21:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2311,
|
|
"name": "_targetPath",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2209,
|
|
"src": "4393:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2315,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2314,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2312,
|
|
"name": "n",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2296,
|
|
"src": "4405:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "-",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "31",
|
|
"id": 2313,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4409:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_1_by_1",
|
|
"typeString": "int_const 1"
|
|
},
|
|
"value": "1"
|
|
},
|
|
"src": "4405:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4393:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "4369:42:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2317,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4369:42:1"
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2301,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2299,
|
|
"name": "n",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2296,
|
|
"src": "4340:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": ">",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2300,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4344:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"src": "4340:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2318,
|
|
"initializationExpression": {
|
|
"assignments": [
|
|
2296
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2296,
|
|
"mutability": "mutable",
|
|
"name": "n",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2318,
|
|
"src": "4325:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2295,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4325:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2298,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"id": 2297,
|
|
"name": "j",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2230,
|
|
"src": "4337:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "4325:13:1"
|
|
},
|
|
"loopExpression": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2303,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "--",
|
|
"prefix": false,
|
|
"src": "4347:3:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2302,
|
|
"name": "n",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2296,
|
|
"src": "4347:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2304,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4347:3:1"
|
|
},
|
|
"nodeType": "ForStatement",
|
|
"src": "4320:91:1"
|
|
},
|
|
{
|
|
"assignments": [
|
|
2320
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2320,
|
|
"mutability": "mutable",
|
|
"name": "length",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2383,
|
|
"src": "4428:14:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2319,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4428:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2322,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2321,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4445:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "4428:18:1"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2376,
|
|
"nodeType": "Block",
|
|
"src": "4506:231:1",
|
|
"statements": [
|
|
{
|
|
"body": {
|
|
"id": 2365,
|
|
"nodeType": "Block",
|
|
"src": "4582:97:1",
|
|
"statements": [
|
|
{
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"id": 2359,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2353,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4609:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2355,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2354,
|
|
"name": "p",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2324,
|
|
"src": "4614:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4609:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "==",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2356,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4620:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2358,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2357,
|
|
"name": "q",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2336,
|
|
"src": "4625:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4620:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "4609:18:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"falseBody": null,
|
|
"id": 2364,
|
|
"nodeType": "IfStatement",
|
|
"src": "4605:54:1",
|
|
"trueBody": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2362,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2360,
|
|
"name": "p",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2324,
|
|
"src": "4654:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2361,
|
|
"name": "q",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2336,
|
|
"src": "4658:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "4654:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2363,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4654:5:1"
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2348,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2341,
|
|
"name": "q",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2336,
|
|
"src": "4549:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "<",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2347,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2342,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4553:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2343,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "4553:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "-",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2346,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2344,
|
|
"name": "p",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2324,
|
|
"src": "4567:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "%",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "32",
|
|
"id": 2345,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4571:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_2_by_1",
|
|
"typeString": "int_const 2"
|
|
},
|
|
"value": "2"
|
|
},
|
|
"src": "4567:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "4553:19:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "4549:23:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2366,
|
|
"initializationExpression": {
|
|
"assignments": [
|
|
2336
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2336,
|
|
"mutability": "mutable",
|
|
"name": "q",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2366,
|
|
"src": "4530:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2335,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4530:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2340,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2339,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2337,
|
|
"name": "p",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2324,
|
|
"src": "4542:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "+",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "32",
|
|
"id": 2338,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4546:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_2_by_1",
|
|
"typeString": "int_const 2"
|
|
},
|
|
"value": "2"
|
|
},
|
|
"src": "4542:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "4530:17:1"
|
|
},
|
|
"loopExpression": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2351,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2349,
|
|
"name": "q",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2336,
|
|
"src": "4574:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "+=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"hexValue": "32",
|
|
"id": 2350,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4579:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_2_by_1",
|
|
"typeString": "int_const 2"
|
|
},
|
|
"value": "2"
|
|
},
|
|
"src": "4574:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2352,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4574:6:1"
|
|
},
|
|
"nodeType": "ForStatement",
|
|
"src": "4525:154:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2374,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2367,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4697:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2370,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2369,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "++",
|
|
"prefix": false,
|
|
"src": "4702:8:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2368,
|
|
"name": "length",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2320,
|
|
"src": "4702:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4697:14:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2371,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4714:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2373,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2372,
|
|
"name": "p",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2324,
|
|
"src": "4719:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "4714:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "4697:24:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2375,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4697:24:1"
|
|
}
|
|
]
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2330,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2327,
|
|
"name": "p",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2324,
|
|
"src": "4481:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "<",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2328,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4485:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2329,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "4485:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "4481:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2377,
|
|
"initializationExpression": {
|
|
"assignments": [
|
|
2324
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2324,
|
|
"mutability": "mutable",
|
|
"name": "p",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2377,
|
|
"src": "4466:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2323,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4466:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2326,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2325,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4478:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "4466:13:1"
|
|
},
|
|
"loopExpression": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2333,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2331,
|
|
"name": "p",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2324,
|
|
"src": "4498:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "+=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"hexValue": "31",
|
|
"id": 2332,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4503:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_1_by_1",
|
|
"typeString": "int_const 1"
|
|
},
|
|
"value": "1"
|
|
},
|
|
"src": "4498:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2334,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "4498:6:1"
|
|
},
|
|
"nodeType": "ForStatement",
|
|
"src": "4461:276:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2379,
|
|
"name": "path",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2265,
|
|
"src": "4776:4:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2380,
|
|
"name": "length",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2320,
|
|
"src": "4782:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
},
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"id": 2378,
|
|
"name": "getPartialArray",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2531,
|
|
"src": "4760:15:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_internal_pure$_t_array$_t_address_$dyn_memory_ptr_$_t_uint256_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (address[] memory,uint256) pure returns (address[] memory)"
|
|
}
|
|
},
|
|
"id": 2381,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "4760:29:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2214,
|
|
"id": 2382,
|
|
"nodeType": "Return",
|
|
"src": "4753:36:1"
|
|
}
|
|
]
|
|
}
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2388,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "4834:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
}
|
|
],
|
|
"id": 2387,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "NewExpression",
|
|
"src": "4820:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_objectcreation_pure$_t_uint256_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (uint256) pure returns (address[] memory)"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2385,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "4824:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2386,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "4824:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
}
|
|
},
|
|
"id": 2389,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "4820:16:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2214,
|
|
"id": 2390,
|
|
"nodeType": "Return",
|
|
"src": "4813:23:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 2203,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "3495:229:1",
|
|
"text": " @dev merges two paths with a common suffix into one\n @param _sourcePath address of the source path\n @param _targetPath address of the target path\n @return merged path"
|
|
},
|
|
"id": 2392,
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "getShortestPath",
|
|
"nodeType": "FunctionDefinition",
|
|
"overrides": null,
|
|
"parameters": {
|
|
"id": 2210,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2206,
|
|
"mutability": "mutable",
|
|
"name": "_sourcePath",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2392,
|
|
"src": "3755:28:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2204,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3755:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2205,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "3755:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 2209,
|
|
"mutability": "mutable",
|
|
"name": "_targetPath",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2392,
|
|
"src": "3785:28:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2207,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3785:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2208,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "3785:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "3754:60:1"
|
|
},
|
|
"returnParameters": {
|
|
"id": 2214,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2213,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2392,
|
|
"src": "3837:16:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2211,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "3837:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2212,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "3837:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "3836:18:1"
|
|
},
|
|
"scope": 2532,
|
|
"src": "3730:1114:1",
|
|
"stateMutability": "pure",
|
|
"virtual": false,
|
|
"visibility": "private"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2420,
|
|
"nodeType": "Block",
|
|
"src": "5084:110:1",
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
2405
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2405,
|
|
"mutability": "mutable",
|
|
"name": "array",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2420,
|
|
"src": "5095:22:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2403,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5095:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2404,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "5095:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2411,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"hexValue": "31",
|
|
"id": 2409,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "5134:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_1_by_1",
|
|
"typeString": "int_const 1"
|
|
},
|
|
"value": "1"
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_rational_1_by_1",
|
|
"typeString": "int_const 1"
|
|
}
|
|
],
|
|
"id": 2408,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "NewExpression",
|
|
"src": "5120:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_objectcreation_pure$_t_uint256_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (uint256) pure returns (address[] memory)"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2406,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5124:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2407,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "5124:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
}
|
|
},
|
|
"id": 2410,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "5120:16:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "5095:41:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2416,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2412,
|
|
"name": "array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2405,
|
|
"src": "5147:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2414,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2413,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "5153:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "5147:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2415,
|
|
"name": "_item",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2395,
|
|
"src": "5158:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "5147:16:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2417,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "5147:16:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2418,
|
|
"name": "array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2405,
|
|
"src": "5181:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2400,
|
|
"id": 2419,
|
|
"nodeType": "Return",
|
|
"src": "5174:12:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 2393,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "4852:146:1",
|
|
"text": " @dev creates a new array containing a single item\n @param _item item\n @return initial array"
|
|
},
|
|
"id": 2421,
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "getInitialArray",
|
|
"nodeType": "FunctionDefinition",
|
|
"overrides": null,
|
|
"parameters": {
|
|
"id": 2396,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2395,
|
|
"mutability": "mutable",
|
|
"name": "_item",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2421,
|
|
"src": "5029:13:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 2394,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5029:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "5028:15:1"
|
|
},
|
|
"returnParameters": {
|
|
"id": 2400,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2399,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2421,
|
|
"src": "5066:16:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2397,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5066:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2398,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "5066:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "5065:18:1"
|
|
},
|
|
"scope": 2532,
|
|
"src": "5004:190:1",
|
|
"stateMutability": "pure",
|
|
"virtual": false,
|
|
"visibility": "private"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2485,
|
|
"nodeType": "Block",
|
|
"src": "5560:247:1",
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
2439
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2439,
|
|
"mutability": "mutable",
|
|
"name": "array",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2485,
|
|
"src": "5571:22:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2437,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5571:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2438,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "5571:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2448,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2446,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "32",
|
|
"id": 2443,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "5610:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_2_by_1",
|
|
"typeString": "int_const 2"
|
|
},
|
|
"value": "2"
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "+",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2444,
|
|
"name": "_array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2429,
|
|
"src": "5614:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2445,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "5614:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "5610:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"id": 2442,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "NewExpression",
|
|
"src": "5596:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_objectcreation_pure$_t_uint256_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (uint256) pure returns (address[] memory)"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2440,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5600:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2441,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "5600:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
}
|
|
},
|
|
"id": 2447,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "5596:32:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "5571:57:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2453,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2449,
|
|
"name": "array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2439,
|
|
"src": "5639:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2451,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2450,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "5645:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "5639:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2452,
|
|
"name": "_item0",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2424,
|
|
"src": "5650:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "5639:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2454,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "5639:17:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2459,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2455,
|
|
"name": "array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2439,
|
|
"src": "5667:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2457,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "31",
|
|
"id": 2456,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "5673:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_1_by_1",
|
|
"typeString": "int_const 1"
|
|
},
|
|
"value": "1"
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "5667:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"id": 2458,
|
|
"name": "_item1",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2426,
|
|
"src": "5678:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "5667:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2460,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "5667:17:1"
|
|
},
|
|
{
|
|
"body": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2480,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2472,
|
|
"name": "array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2439,
|
|
"src": "5752:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2476,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2475,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"hexValue": "32",
|
|
"id": 2473,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "5758:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_2_by_1",
|
|
"typeString": "int_const 2"
|
|
},
|
|
"value": "2"
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "+",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2474,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2462,
|
|
"src": "5762:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "5758:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "5752:12:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2477,
|
|
"name": "_array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2429,
|
|
"src": "5767:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2479,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2478,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2462,
|
|
"src": "5774:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "5767:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "5752:24:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2481,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "5752:24:1"
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2468,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2465,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2462,
|
|
"src": "5715:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "<",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2466,
|
|
"name": "_array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2429,
|
|
"src": "5719:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2467,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"memberName": "length",
|
|
"nodeType": "MemberAccess",
|
|
"referencedDeclaration": null,
|
|
"src": "5719:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "5715:17:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2482,
|
|
"initializationExpression": {
|
|
"assignments": [
|
|
2462
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2462,
|
|
"mutability": "mutable",
|
|
"name": "i",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2482,
|
|
"src": "5700:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2461,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5700:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2464,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2463,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "5712:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "5700:13:1"
|
|
},
|
|
"loopExpression": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2470,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "++",
|
|
"prefix": false,
|
|
"src": "5734:3:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2469,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2462,
|
|
"src": "5734:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2471,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "5734:3:1"
|
|
},
|
|
"nodeType": "ForStatement",
|
|
"src": "5695:81:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2483,
|
|
"name": "array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2439,
|
|
"src": "5794:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2434,
|
|
"id": 2484,
|
|
"nodeType": "Return",
|
|
"src": "5787:12:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 2422,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "5202:229:1",
|
|
"text": " @dev prepends two items to the beginning of an array\n @param _item0 first item\n @param _item1 second item\n @param _array initial array\n @return extended array"
|
|
},
|
|
"id": 2486,
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "getExtendedArray",
|
|
"nodeType": "FunctionDefinition",
|
|
"overrides": null,
|
|
"parameters": {
|
|
"id": 2430,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2424,
|
|
"mutability": "mutable",
|
|
"name": "_item0",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2486,
|
|
"src": "5463:14:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 2423,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5463:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 2426,
|
|
"mutability": "mutable",
|
|
"name": "_item1",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2486,
|
|
"src": "5479:14:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
},
|
|
"typeName": {
|
|
"id": 2425,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5479:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 2429,
|
|
"mutability": "mutable",
|
|
"name": "_array",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2486,
|
|
"src": "5495:23:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2427,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5495:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2428,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "5495:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "5462:57:1"
|
|
},
|
|
"returnParameters": {
|
|
"id": 2434,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2433,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2486,
|
|
"src": "5542:16:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2431,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "5542:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2432,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "5542:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "5541:18:1"
|
|
},
|
|
"scope": 2532,
|
|
"src": "5437:370:1",
|
|
"stateMutability": "pure",
|
|
"virtual": false,
|
|
"visibility": "private"
|
|
},
|
|
{
|
|
"body": {
|
|
"id": 2530,
|
|
"nodeType": "Block",
|
|
"src": "6112:171:1",
|
|
"statements": [
|
|
{
|
|
"assignments": [
|
|
2502
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2502,
|
|
"mutability": "mutable",
|
|
"name": "array",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2530,
|
|
"src": "6123:22:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2500,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6123:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2501,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "6123:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2508,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"arguments": [
|
|
{
|
|
"argumentTypes": null,
|
|
"id": 2506,
|
|
"name": "_length",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2492,
|
|
"src": "6162:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
}
|
|
],
|
|
"expression": {
|
|
"argumentTypes": [
|
|
{
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
],
|
|
"id": 2505,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"lValueRequested": false,
|
|
"nodeType": "NewExpression",
|
|
"src": "6148:13:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_function_objectcreation_pure$_t_uint256_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
|
|
"typeString": "function (uint256) pure returns (address[] memory)"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2503,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6152:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2504,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "6152:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
}
|
|
},
|
|
"id": 2507,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"kind": "functionCall",
|
|
"lValueRequested": false,
|
|
"names": [],
|
|
"nodeType": "FunctionCall",
|
|
"src": "6148:22:1",
|
|
"tryCall": false,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "6123:47:1"
|
|
},
|
|
{
|
|
"body": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2525,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2519,
|
|
"name": "array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2502,
|
|
"src": "6232:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2521,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2520,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2510,
|
|
"src": "6238:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": true,
|
|
"nodeType": "IndexAccess",
|
|
"src": "6232:8:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"nodeType": "Assignment",
|
|
"operator": "=",
|
|
"rightHandSide": {
|
|
"argumentTypes": null,
|
|
"baseExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2522,
|
|
"name": "_array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2490,
|
|
"src": "6243:6:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"id": 2524,
|
|
"indexExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2523,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2510,
|
|
"src": "6250:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"isConstant": false,
|
|
"isLValue": true,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "IndexAccess",
|
|
"src": "6243:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"src": "6232:20:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2526,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "6232:20:1"
|
|
},
|
|
"condition": {
|
|
"argumentTypes": null,
|
|
"commonType": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"id": 2515,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"leftExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2513,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2510,
|
|
"src": "6201:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"nodeType": "BinaryOperation",
|
|
"operator": "<",
|
|
"rightExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2514,
|
|
"name": "_length",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2492,
|
|
"src": "6205:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"src": "6201:11:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_bool",
|
|
"typeString": "bool"
|
|
}
|
|
},
|
|
"id": 2527,
|
|
"initializationExpression": {
|
|
"assignments": [
|
|
2510
|
|
],
|
|
"declarations": [
|
|
{
|
|
"constant": false,
|
|
"id": 2510,
|
|
"mutability": "mutable",
|
|
"name": "i",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2527,
|
|
"src": "6186:9:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2509,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6186:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"id": 2512,
|
|
"initialValue": {
|
|
"argumentTypes": null,
|
|
"hexValue": "30",
|
|
"id": 2511,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": true,
|
|
"kind": "number",
|
|
"lValueRequested": false,
|
|
"nodeType": "Literal",
|
|
"src": "6198:1:1",
|
|
"subdenomination": null,
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_rational_0_by_1",
|
|
"typeString": "int_const 0"
|
|
},
|
|
"value": "0"
|
|
},
|
|
"nodeType": "VariableDeclarationStatement",
|
|
"src": "6186:13:1"
|
|
},
|
|
"loopExpression": {
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2517,
|
|
"isConstant": false,
|
|
"isLValue": false,
|
|
"isPure": false,
|
|
"lValueRequested": false,
|
|
"nodeType": "UnaryOperation",
|
|
"operator": "++",
|
|
"prefix": false,
|
|
"src": "6214:3:1",
|
|
"subExpression": {
|
|
"argumentTypes": null,
|
|
"id": 2516,
|
|
"name": "i",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2510,
|
|
"src": "6214:1:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"id": 2518,
|
|
"nodeType": "ExpressionStatement",
|
|
"src": "6214:3:1"
|
|
},
|
|
"nodeType": "ForStatement",
|
|
"src": "6181:71:1"
|
|
},
|
|
{
|
|
"expression": {
|
|
"argumentTypes": null,
|
|
"id": 2528,
|
|
"name": "array",
|
|
"nodeType": "Identifier",
|
|
"overloadedDeclarations": [],
|
|
"referencedDeclaration": 2502,
|
|
"src": "6270:5:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[] memory"
|
|
}
|
|
},
|
|
"functionReturnParameters": 2497,
|
|
"id": 2529,
|
|
"nodeType": "Return",
|
|
"src": "6263:12:1"
|
|
}
|
|
]
|
|
},
|
|
"documentation": {
|
|
"id": 2487,
|
|
"nodeType": "StructuredDocumentation",
|
|
"src": "5815:184:1",
|
|
"text": " @dev extracts the prefix of a given array\n @param _array given array\n @param _length prefix length\n @return partial array"
|
|
},
|
|
"id": 2531,
|
|
"implemented": true,
|
|
"kind": "function",
|
|
"modifiers": [],
|
|
"name": "getPartialArray",
|
|
"nodeType": "FunctionDefinition",
|
|
"overrides": null,
|
|
"parameters": {
|
|
"id": 2493,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2490,
|
|
"mutability": "mutable",
|
|
"name": "_array",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2531,
|
|
"src": "6030:23:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2488,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6030:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2489,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "6030:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
},
|
|
{
|
|
"constant": false,
|
|
"id": 2492,
|
|
"mutability": "mutable",
|
|
"name": "_length",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2531,
|
|
"src": "6055:15:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "default",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
},
|
|
"typeName": {
|
|
"id": 2491,
|
|
"name": "uint256",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6055:7:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_uint256",
|
|
"typeString": "uint256"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "6029:42:1"
|
|
},
|
|
"returnParameters": {
|
|
"id": 2497,
|
|
"nodeType": "ParameterList",
|
|
"parameters": [
|
|
{
|
|
"constant": false,
|
|
"id": 2496,
|
|
"mutability": "mutable",
|
|
"name": "",
|
|
"nodeType": "VariableDeclaration",
|
|
"overrides": null,
|
|
"scope": 2531,
|
|
"src": "6094:16:1",
|
|
"stateVariable": false,
|
|
"storageLocation": "memory",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
|
|
"typeString": "address[]"
|
|
},
|
|
"typeName": {
|
|
"baseType": {
|
|
"id": 2494,
|
|
"name": "address",
|
|
"nodeType": "ElementaryTypeName",
|
|
"src": "6094:7:1",
|
|
"stateMutability": "nonpayable",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_address",
|
|
"typeString": "address"
|
|
}
|
|
},
|
|
"id": 2495,
|
|
"length": null,
|
|
"nodeType": "ArrayTypeName",
|
|
"src": "6094:9:1",
|
|
"typeDescriptions": {
|
|
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
|
|
"typeString": "address[]"
|
|
}
|
|
},
|
|
"value": null,
|
|
"visibility": "internal"
|
|
}
|
|
],
|
|
"src": "6093:18:1"
|
|
},
|
|
"scope": 2532,
|
|
"src": "6005:278:1",
|
|
"stateMutability": "pure",
|
|
"virtual": false,
|
|
"visibility": "private"
|
|
}
|
|
],
|
|
"scope": 2533,
|
|
"src": "614:5672:1"
|
|
}
|
|
],
|
|
"src": "52:6236:1"
|
|
},
|
|
"compiler": {
|
|
"name": "solc",
|
|
"version": "0.6.12+commit.27d51765.Emscripten.clang"
|
|
},
|
|
"networks": {
|
|
"42": {
|
|
"events": {
|
|
"0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
|
|
"anonymous": false,
|
|
"inputs": [
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_prevOwner",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_newOwner",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "OwnerUpdate",
|
|
"type": "event"
|
|
}
|
|
},
|
|
"links": {},
|
|
"address": "0xf374d7B507767101a4bf3bA2a6B99AC737A44f6d",
|
|
"transactionHash": "0xfd01cc35dbe92ce4e385469a6034518ac7f5e8df1e39f8f58dcbc8082ded1045"
|
|
},
|
|
"8995": {
|
|
"events": {
|
|
"0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
|
|
"anonymous": false,
|
|
"inputs": [
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_prevOwner",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_newOwner",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "OwnerUpdate",
|
|
"type": "event"
|
|
}
|
|
},
|
|
"links": {},
|
|
"address": "0xf374d7B507767101a4bf3bA2a6B99AC737A44f6d",
|
|
"transactionHash": "0xfd01cc35dbe92ce4e385469a6034518ac7f5e8df1e39f8f58dcbc8082ded1045"
|
|
},
|
|
"1604964387852": {
|
|
"events": {
|
|
"0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
|
|
"anonymous": false,
|
|
"inputs": [
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_prevOwner",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_newOwner",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "OwnerUpdate",
|
|
"type": "event"
|
|
}
|
|
},
|
|
"links": {},
|
|
"address": "0x7F6dBD0D9f13EFBcF08FA7817cD6fACc68Fa2C49",
|
|
"transactionHash": "0x5c4a650021d6de7c3eb23bbeaed1a00c142e260e34108a499b9ba22aa25f5427"
|
|
},
|
|
"1604964469407": {
|
|
"events": {
|
|
"0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
|
|
"anonymous": false,
|
|
"inputs": [
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_prevOwner",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_newOwner",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "OwnerUpdate",
|
|
"type": "event"
|
|
}
|
|
},
|
|
"links": {},
|
|
"address": "0x89C7f9CB53F25405f7e98003E57C9f2A8b1a22B8",
|
|
"transactionHash": "0xe38b4943db6d6aefb250565743f7de101363bb9068fd2bf94e98c322ed568e2f"
|
|
},
|
|
"1604965528035": {
|
|
"events": {
|
|
"0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
|
|
"anonymous": false,
|
|
"inputs": [
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_prevOwner",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_newOwner",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "OwnerUpdate",
|
|
"type": "event"
|
|
}
|
|
},
|
|
"links": {},
|
|
"address": "0x7B34ee7EdE799854048b95433f5CB3fA4B82021E",
|
|
"transactionHash": "0x443ea5a694d1e7521a2b78711d8888e28f462b928d7237bb544fe92bdc3fba35"
|
|
},
|
|
"1604965645554": {
|
|
"events": {
|
|
"0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
|
|
"anonymous": false,
|
|
"inputs": [
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_prevOwner",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_newOwner",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "OwnerUpdate",
|
|
"type": "event"
|
|
}
|
|
},
|
|
"links": {},
|
|
"address": "0xa48Af9b8Fab73981F42BA65a33d6921EFee26753",
|
|
"transactionHash": "0x00585976e5e977df22b8061d10ec49eb9b5e898265c4c24442a612a6b7e9d1a5"
|
|
},
|
|
"1604965679541": {
|
|
"events": {
|
|
"0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
|
|
"anonymous": false,
|
|
"inputs": [
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_prevOwner",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_newOwner",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "OwnerUpdate",
|
|
"type": "event"
|
|
}
|
|
},
|
|
"links": {},
|
|
"address": "0x240cba6227Eb9c095a0f2161501d1BA090E9a7d2",
|
|
"transactionHash": "0x872281b0c43b09524e3ae6872560decf9d106cbf071aa4e72ca1175abdcb93b2"
|
|
},
|
|
"1604965719492": {
|
|
"events": {
|
|
"0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
|
|
"anonymous": false,
|
|
"inputs": [
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_prevOwner",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_newOwner",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "OwnerUpdate",
|
|
"type": "event"
|
|
}
|
|
},
|
|
"links": {},
|
|
"address": "0xd4Db57f3Af510F96bE3574EC2A4F70ED3022AC97",
|
|
"transactionHash": "0x57e43c279f5fab7e679e4c44fc9c6cb797477e31158d3b19de6e9c5cebe1ad6c"
|
|
},
|
|
"1604965760834": {
|
|
"events": {
|
|
"0x343765429aea5a34b3ff6a3785a98a5abb2597aca87bfbb58632c173d585373a": {
|
|
"anonymous": false,
|
|
"inputs": [
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_prevOwner",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"indexed": true,
|
|
"internalType": "address",
|
|
"name": "_newOwner",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "OwnerUpdate",
|
|
"type": "event"
|
|
}
|
|
},
|
|
"links": {},
|
|
"address": "0x63D123a3f926fa743008e41eC08Be37EFA28ec23",
|
|
"transactionHash": "0x6b2f52af7972b5c3dde1420abe6aacd2b30cde4157bdcb4ff93f503ef5f66c69"
|
|
}
|
|
},
|
|
"schemaVersion": "3.2.3",
|
|
"updatedAt": "2020-11-10T14:20:41.879Z",
|
|
"networkType": "ethereum",
|
|
"devdoc": {
|
|
"details": "The ConversionPathFinder contract allows generating a conversion path between any token pair in the Bancor Network. The path can then be used in various functions in the BancorNetwork contract. See the BancorNetwork contract for conversion path format.",
|
|
"kind": "dev",
|
|
"methods": {
|
|
"acceptOwnership()": {
|
|
"details": "used by a new owner to accept an ownership transfer"
|
|
},
|
|
"constructor": {
|
|
"details": "initializes a new ConversionPathFinder instance",
|
|
"params": {
|
|
"_registry": "address of a contract registry contract"
|
|
}
|
|
},
|
|
"findPath(address,address)": {
|
|
"details": "generates a conversion path between a given pair of tokens in the Bancor Network",
|
|
"params": {
|
|
"_sourceToken": "address of the source token",
|
|
"_targetToken": "address of the target token"
|
|
},
|
|
"returns": {
|
|
"_0": "a path from the source token to the target token"
|
|
}
|
|
},
|
|
"restoreRegistry()": {
|
|
"details": "restores the previous contract-registry"
|
|
},
|
|
"restrictRegistryUpdate(bool)": {
|
|
"details": "restricts the permission to update the contract-registry",
|
|
"params": {
|
|
"_onlyOwnerCanUpdateRegistry": "indicates whether or not permission is restricted to owner only"
|
|
}
|
|
},
|
|
"setAnchorToken(address)": {
|
|
"details": "updates the anchor token",
|
|
"params": {
|
|
"_anchorToken": "address of the anchor token"
|
|
}
|
|
},
|
|
"transferOwnership(address)": {
|
|
"details": "allows transferring the contract ownership the new owner still needs to accept the transfer can only be called by the contract owner",
|
|
"params": {
|
|
"_newOwner": "new contract owner"
|
|
}
|
|
},
|
|
"updateRegistry()": {
|
|
"details": "updates to the new contract-registry"
|
|
}
|
|
},
|
|
"version": 1
|
|
},
|
|
"userdoc": {
|
|
"kind": "user",
|
|
"methods": {},
|
|
"version": 1
|
|
}
|
|
} |